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

BREAKING: don't parse JSX in .js and .ts files #4385

Open
Tracked by #3727
ematipico opened this issue Oct 25, 2024 · 2 comments
Open
Tracked by #3727

BREAKING: don't parse JSX in .js and .ts files #4385

ematipico opened this issue Oct 25, 2024 · 2 comments
Assignees
Milestone

Comments

@ematipico
Copy link
Member

No description provided.

@ematipico ematipico added this to the Biome 2.0 milestone Oct 25, 2024
@ematipico ematipico self-assigned this Oct 25, 2024
@arendjr
Copy link
Contributor

arendjr commented Oct 25, 2024

For .ts I understand, since the TypeScript compiler makes the same distinction, but why would we do this for .js files? There are plenty of codebases that use .js files with JSX content and it's an accepted practice.

@ematipico
Copy link
Member Author

It's an old and debatable practice. Nowadays, new projects always use .tsx and .jsx straightaway. New and modern projects should rely on file extensions and prior config, see .mjs and .cjs and pakcage.json#type, for example.

We intend to provide an option to opt in to the old behaviour (there's already a task for that in the checklist).

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

2 participants