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
output aliased types in typescript declarations #8629
Conversation
Build successful! You can test your changes in the REPL here: https://babeljs.io/repl/build/9022/ |
1 similar comment
Build successful! You can test your changes in the REPL here: https://babeljs.io/repl/build/9022/ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add tests
Do we have any tests for the generators at all? I'm happy to write some but wasn't sure if we already had any I could extend. |
Yes that's right, sorry. |
I think it doesn't make sense to add tests on the generator, we could instead just commit the file, but the point is to avoid that. |
No worries. It's possible to write tests but they would be type tests rather than unit. Similar to how definitelytyped works. You have a usage file and assert that it compiles. Maybe something for the future. |
Could we get some eyes on this and possibly merge it? Its a very small change but we can't use the shipped TS definitions until then |
We weren't outputting aliased types in our
isXX
assertion methods so we would be losing type information (returningboolean
instead).