-
Notifications
You must be signed in to change notification settings - Fork 42
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
Experiment with using TS Compiler instead of jsdoc #102
Comments
This might be one issue to keep in mind: microsoft/TypeScript#25590 i.e. There is no support for the JSDoc overload syntax. |
There are more issues with jsdoc not supporting TS features than the other way around I'm finding. Not to mention the vscode TS service already parses jsdoc to generate intellisense, so generating a file shouldn't be too hard. |
Unless I'm misunderstanding you, this is already possible and quite easy actually (see an example here). Unfortunately I ran into 2 blocking issues (noted at the end of the above-mentioned comment). |
I just meant using typescript to parse the jsdoc comments instead of using jsdoc to parse the jsdoc comments. |
I should try using the typescript compiler to parse the JS and generate definitions rather than using jsdoc directly. We've encountered a number of bugs related to how jsdoc parses JS and it not keeping up with JS features. Maybe we can get better results by using TS only and dropping jsdoc.
The idea would be to still use jsdoc comments to generate type defs, but to not use the jsdoc parser directly.
If anyone has thoughts, please share them.
The text was updated successfully, but these errors were encountered: