Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

isConst flag not set for constants #1866

Closed
niekvb opened this issue Feb 7, 2022 · 1 comment
Closed

isConst flag not set for constants #1866

niekvb opened this issue Feb 7, 2022 · 1 comment
Labels
bug Functionality does not match expectation

Comments

@niekvb
Copy link

niekvb commented Feb 7, 2022

Search terms

isConst, variables, constants, flags

Expected Behavior

Expected isConst flag to be set when DeclarationReflection.kind is ReflectionKind.Variable.

Actual Behavior

The isConst is not set when the reflected item is a const.

Steps to reproduce the bug

export const TEST_CONST: string = "";

Console.log output of the DeclarationReflection:

{
  id: 1198,
  name: 'TEST_CONST',
  kind: 32,
  kindString: 'Variable',
  flags: {},
  comment: { ... },
  decorates: undefined,
  decorators: undefined,
  children: undefined,
  groups: undefined,
  categories: undefined,
  sources: [ { ... } ],
  typeParameter: undefined,
  type: { type: 'intrinsic', name: 'string' },
  signatures: undefined,
  indexSignature: undefined,
  defaultValue: '""',
  overwrites: undefined,
  inheritedFrom: undefined,
  implementationOf: undefined,
  extendedTypes: undefined,
  extendedBy: undefined,
  implementedTypes: undefined,
  implementedBy: undefined,
  parentId: 1192
}

Environment

  • Typedoc version: 0.22.11
  • TypeScript version: 4.5.5
  • Node.js version: 14.15.4
  • OS: WSL Ubuntu 20.04 on Windows 10 Pro (build 19043.1415)
@niekvb niekvb added the bug Functionality does not match expectation label Feb 7, 2022
@niekvb
Copy link
Author

niekvb commented Feb 7, 2022

Might be related to #1804 and #1810

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Functionality does not match expectation
Projects
None yet
Development

No branches or pull requests

1 participant