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

export-default-from proposal is enabled #9473

Open
char0n opened this issue Jan 8, 2024 · 3 comments
Open

export-default-from proposal is enabled #9473

char0n opened this issue Jan 8, 2024 · 3 comments
Labels

Comments

@char0n
Copy link

char0n commented Jan 8, 2024

Here is an example:

const from = 3;
export default from;

@parcel/transformer-js: Unexpected token ;. Expected a string literal


The code uses reserved keyword from, but in this context it's completely valid JavaScript.

@mischnic
Copy link
Member

mischnic commented Jan 8, 2024

I'm not entirely sure why, Parcel has the export-default-from proposal enabled:

export_default_from: true,

and according to that, what you're seeing is the correct behaviour...
tc39/proposal-export-default-from#2

@char0n
Copy link
Author

char0n commented Jan 9, 2024

Hi @mischnic,

Ahh, interesting that parcel is implementing Stage 1 proposals. Anyway it's clear now why it happens. Thanks! I've adopted naming changes withing the code to void situation however the proposal endup.

@mischnic mischnic changed the title Certain syntax breaks parcel export-default-from proposal is enabled Jan 9, 2024
@github-actions github-actions bot added the Stale Inactive issues label Jul 7, 2024
@parcel-bundler parcel-bundler deleted a comment from github-actions bot Jul 7, 2024
@mischnic mischnic removed the Stale Inactive issues label Jul 7, 2024
Copy link

github-actions bot commented Jan 4, 2025

This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 14 days if no further activity occurs.

@github-actions github-actions bot added the Stale Inactive issues label Jan 4, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants