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

[api]: some typescript types do not render properly #16

Open
bennypowers opened this issue Mar 5, 2021 · 0 comments
Open

[api]: some typescript types do not render properly #16

bennypowers opened this issue Mar 5, 2021 · 0 comments

Comments

@bennypowers
Copy link
Member

Some complex types are not rendering properly

See for example https://github.com/atom-community/atom-ide-base/blob/1120181f51973a13bee8dd899a8accbc115182f8/types-packages/code-actions.d.ts#L38

This should render as something like

(diagnostic: Diagnostic, editor: Atom.TextEditor) => Promise<CodeAction[]>

Instead, our type renderer just throws its hands up and renders an empty string:

Screen Shot 2021-03-05 at 9 57 58

The relevant code lives in https://github.com/atom-community/atom-community.github.io/blob/master/docs/_includes/_joiningBlocks/_layoutApi/content/20-api.njk#L21

Part of the problem is that our input is TypeDoc reflection JSON, and we're trying to turn that back into TypeScript snippets. We haven't covered every case yet.

Relevant upstream PR: TypeStrong/typedoc#1216

This package, or code from it, may be of use: https://www.npmjs.com/package/typedoc-plugin-typescript-declaration

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant