-
-
Notifications
You must be signed in to change notification settings - Fork 572
Add decorators in ESTree for JS files #10921
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
Comments
@ArnaudBarre Same question as #10978 (comment): What other parsers used in Prettier can parse decorators (apart from TS-ESLint)? I'm struggling to work out how we can test this, because our testing infra is based around comparing to an existing implementation. TS-ESLint adds |
Ah ha I have my answer as to which types should get But is there a reference implementation we can use for tests which follows this spec? |
flow and meriyah Same answer #10978 (comment), mentioned in #10979, we can't ignore decorators, we need error to refuse formatting if not planned to support. |
Thanks for coming back. Perhaps we can add I guess another option is to try to conform to @babel/eslint-parser. That would be more future-proof, as new features always get implemented in Babel first. Either way, I'll need to complete the work on field ordering first (#9705 (comment)), because different parsers definitely differ in that respect. |
oxc-parser has landed in prettier, this is the last blocking issue before its stable release. |
Very much aware! I'm working on it. |
Playground
There are visible in the Rust AST, is this something wanted to not exposed them? It's only stage 3 but given that they are already parsed, I think it's better to make them available than skip them
The text was updated successfully, but these errors were encountered: