We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
declare module
namespace
This input:
declare module "m" { export function f(); }
generates this JSON output:
{ "id": 0, "name": "", "kind": 0, "flags": {}, "originalName": "", "children": [ { "id": 1, "name": "\"m\"", "kind": 2, "kindString": "Namespace", "flags": { "isExported": true }, "children": [ { "id": 2, "name": "f", "kind": 64, "kindString": "Function", "flags": { "isExported": true }, "signatures": [ { "id": 3, "name": "f", "kind": 4096, "kindString": "Call signature", "flags": { "isExported": true }, "type": { "type": "intrinsic", "name": "any" } } ], } ], "groups": [ { "title": "Functions", "kind": 64, "children": [ 2 ] } ], } ], "groups": [ { "title": "Namespaces", "kind": 2, "children": [ 1 ] } ] }
I was expecting reflection with id = 1 to be of kind = 1 (module), not of kind = 2 (namespace)
The text was updated successfully, but these errors were encountered:
interface
Looks like this is because in the AST, this creates a ModuleDeclaration node, which is the same node type created by namespaces.
ModuleDeclaration
Should be a pretty simple fix to switch the kind argument to createDeclaration if the name of the node is a StringLiteral - https://github.com/TypeStrong/typedoc/blob/master/src/lib/converter/nodes/module.ts
kind
createDeclaration
StringLiteral
Sorry, something went wrong.
fix: Module declaration parsed as namespace (#1301)
4fed0bd
Closes #1284
v0.17.7 released with this :)
Awesome. Thank you!
Successfully merging a pull request may close this issue.
This input:
generates this JSON output:
I was expecting reflection with id = 1 to be of kind = 1 (module), not of kind = 2 (namespace)
The text was updated successfully, but these errors were encountered: