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

syntax without whitespaces is not supported #3

Open
tmcw opened this issue Sep 24, 2018 · 4 comments
Open

syntax without whitespaces is not supported #3

tmcw opened this issue Sep 24, 2018 · 4 comments

Comments

@tmcw
Copy link

tmcw commented Sep 24, 2018

Test example:

export{c as luminance,o as rgb,s as hex,f as score};

This fails the isModule check, whereas a single export, like:

export{c as luminance};

Is correctly flagged as module.

@natevw
Copy link

natevw commented Mar 26, 2019

Good catch! I think this is the actual cause of rollup/rollup-plugin-node-resolve#200.

@timaschew
Copy link
Member

timaschew commented Mar 27, 2019

export{c as luminance,o as rgb,s as hex,f as score};

export{c as luminance};

Actually none of the both examples works for me, both are returning false because of a missing whitespace between export and {

Anyway I've updated the pattern and added some tests. Now it's working.

Unfortunately I don't have permissions on npm (yet) to publish a new version.

@clintwood @jonathanong @trevorgerhardt please can anyone of you give me permissions :)

@timaschew timaschew changed the title Multi-export form not supported syntax without whitespaces is not supported Mar 28, 2019
@timaschew timaschew reopened this Apr 2, 2019
@timaschew
Copy link
Member

ping @jonathanong @trevorgerhardt

@natevw
Copy link

natevw commented Apr 2, 2019

Not sure if this is still the same issue anymore, but would looking for \b instead of \s at least help match the actual JS grammar here?

Note the caution in MDN doc link:

Accented characters, such as "é" or "ü" are, unfortunately, treated as non-word characters for the purposes of word boundaries, as are ideographic characters in general.

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

3 participants