Skip to content

In JSDoc, resolve import types as values too #26066

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

Merged
merged 2 commits into from
Jul 31, 2018

Conversation

sandersn
Copy link
Member

This is something that we probably should have been doing for some time.
Fixes #26049

This is something that we probably should have been doing for some time.
Fixes #26049
@sandersn sandersn requested review from weswigham and mhegazy July 30, 2018 19:30
Copy link
Member

@weswigham weswigham left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

While this jibes with what we had done in the past for other jsdocs, I think we should probably be binding with the desired meaning in the first place (esp. since in this case there's no ambiguity about if a type is needed like with a function declaration - the @enum tag ensures there will be both a type and a value!). That's probably a larger change, though. 🤷‍♂️

@sandersn
Copy link
Member Author

Yes, I agree in general. It's nice to have this as a fallback, though. And for the specific case of @enum, it's mostly supported to enable closure codebases to work better in typescript, so I don't think it justifies a ton of effort.

@sandersn sandersn merged commit a21ac11 into master Jul 31, 2018
@sandersn sandersn deleted the jsdoc/resolve-import-types-as-values-too branch July 31, 2018 18:07
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

Successfully merging this pull request may close these issues.

2 participants