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
This TypeScript code crashes both Babel and Sucrase, but works in tsc:
const f: ({a}: {a: number}) => void = () => {};
Playground link
A workaround is to simply avoid the destructure, like defining the type as (args: {a: number}) => void, since the destructure doesn't do anything.
(args: {a: number}) => void
The text was updated successfully, but these errors were encountered:
Fix crash on destructured params in arrow function types
69e746e
Fixes #277 There's a decision point on whether the upcoming type is a function type or not, and it wasn't considering destructured params.
Fix crash on destructured params in arrow function types (#278)
fa87ab0
alangpierce
No branches or pull requests
This TypeScript code crashes both Babel and Sucrase, but works in tsc:
Playground link
A workaround is to simply avoid the destructure, like defining the type as
(args: {a: number}) => void
, since the destructure doesn't do anything.The text was updated successfully, but these errors were encountered: