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

TypeScript 5.2 features #15894

Closed
3 tasks
nicolo-ribaudo opened this issue Aug 25, 2023 · 4 comments
Closed
3 tasks

TypeScript 5.2 features #15894

nicolo-ribaudo opened this issue Aug 25, 2023 · 4 comments
Labels
area: typescript good first issue i: enhancement outdated A closed issue/PR that is archived due to age. Recommended to make a new issue
Milestone

Comments

@nicolo-ribaudo
Copy link
Member

nicolo-ribaudo commented Aug 25, 2023

💻

  • Would you like to work on this feature?

What problem are you trying to solve?

We need to make sure we support all the TS 5.2 features: https://devblogs.microsoft.com/typescript/announcing-typescript-5-2/

The missing ones are:

Everything else seems to be supported

Describe the solution you'd like

/

Describe alternatives you've considered

/

Documentation, Adoption, Migration Strategy

No response

@nicolo-ribaudo
Copy link
Member Author

Named and Anonymous Tuple Elements: [first: T, T] is now a valid type

For this change, we just need to delete the error about mixing tuple elements with and without labels from our parser. Tuples parsing is implemented at

tsParseTupleType(): N.TsTupleType {
.

Then, there will probably be some tests that can be deleted because they were testing that error.


If it is the first time that you contribute to Babel, follow these steps: (you need to have make and yarn available on your machine)

  1. Write a comment there to let other possible contributors know that you are working on this bug.
  2. Fork the repo
  3. Run git clone https://github.com/<YOUR_USERNAME>/babel.git && cd babel
  4. Run yarn && make bootstrap
  5. Wait ⏳
  6. Run make watch (or make build whenever you change a file)
  7. Add a test (only input.ts; output.json will be automatically generated)
  8. Update the code!
  9. yarn jest babel-parser to run the tests
    • If some test outputs don't match but the new results are correct, you can delete the bad output.js files and run the tests again
    • If you prefer, you can run OVERWRITE=true yarn jest babel-parser and they will be automatically updated.
  10. If it is working, run make test to run all the tests
  11. Run git push and open a PR!

@yukukotani
Copy link
Contributor

I'm going to work on Named and Anonymous Tuple Elements

@ShiviTripathi13
Copy link

Is this issue still open, if yes, please assign it to me.

@liuxingbaoyu
Copy link
Member

@ShiviTripathi13 Thank you! Now they have been completed. :)

@github-actions github-actions bot added the outdated A closed issue/PR that is archived due to age. Recommended to make a new issue label Dec 30, 2023
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Dec 30, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area: typescript good first issue i: enhancement outdated A closed issue/PR that is archived due to age. Recommended to make a new issue
Projects
None yet
Development

No branches or pull requests

4 participants