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

JSX Tracing #2525

Open
guybedford opened this issue Dec 5, 2020 · 0 comments
Open

JSX Tracing #2525

guybedford opened this issue Dec 5, 2020 · 0 comments

Comments

@guybedford
Copy link
Member

Since JSX / TSX support was added, the es-module-lexer doesn't have full JSX parser capabilities.

We should do a preparse of JSX files before the lexer by detecting the .jsx or .tsx extensions and running a very lightweight JSX transform before performing the analysis. Most likely we should just do a Babel parse to get the import list instead of using es-module-lexer in this case.

Extending es-module-lexer to support JSX via the grammar at https://facebook.github.io/jsx/ is another possibility.

@guybedford guybedford transferred this issue from another repository Apr 8, 2023
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

No branches or pull requests

1 participant