Closed robrez closed 2 years ago
Sorry, I don't have a great, minimal reproduction example.. I depend on es-module-lexer transitively from @web/dev-server
es-module-lexer
Since 1.0.4, started receiving a syntax error for code that looks like this:
1.0.4
foo.js
const css = String.raw; export default css`:host { solid 1px black }`;
bar.js
import foo from '@org/foo.js';`
@web/dev-server reports the the error as:
@web/dev-server
Error while transforming node_modules\@org/foo.js: Syntax error 1 | const css = String.raw; 2 | export default css`:host { solid 1px black }`; > 3 | | ^
Note that if I change the code, this works:
const css = String.raw; const blah = css`:host { solid 1px black }`; export default blah;
My remedial action has been to pin es-module-lexer in my package.json... ^1.0.0 <=1.0.3
^1.0.0 <=1.0.3
Thanks for sharing the case and version, that helps a lot. Fixed in 1.0.5.
Sorry, I don't have a great, minimal reproduction example.. I depend on
es-module-lexer
transitively from @web/dev-serverSince
1.0.4
, started receiving a syntax error for code that looks like this:foo.js
bar.js
@web/dev-server
reports the the error as:Note that if I change the code, this works:
My remedial action has been to pin
es-module-lexer
in my package.json...^1.0.0 <=1.0.3