Closed aomarks closed 2 years ago
Update: this doesn't occur in v0.9.1, so seems to be a recent regression. https://github.com/guybedford/es-module-lexer/pull/89 perhaps?
Hi @aomarks thanks for the report here, and glad to hear it's in use there. You're exactly right this was a 0.9.1 regression, I'm releasing a fix via https://github.com/guybedford/es-module-lexer/pull/93 in 0.9.2 0.9.3 now.
If there is a comment inside of an
ImportsList
, and that comment contains a}
, then es-module-lexer v0.9.2 currently throws a parse error:If there is no
}
inside the comment, then there is no parse error.Found in the wild here: https://unpkg.com/@lion/combobox@0.8.4/lion-combobox.js
(Love this library by the way! We are using it in https://github.com/google/playground-elements which powers https://lit.dev/playground/ to do super fast bare module resolution. You can see the parse error as an inline red squiggly error in this example).