You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ES modules are not supported in Node and as expected I did not provide any solution for parsing this module types.
I think you should prefer commonjs modules in webpack configuration.
It's not a huge deal, but I prefer to use import statements everywhere to keep my code more consistent and do less context switching. What's your reasoning for preferring commonjs modules in Webpack configs?
Also, I presume plenty of people are using import statements through Babel and std/esm could become popular.
My package.json
"jest": { "resolver": "jest-webpack-resolver", "transform": { "^.+\\.jsx?$": "babel-jest" } }
My test script is just
"test": "jest"
My error message comes from my webpack config and states:
import path from 'path'; SyntaxError: Unexpected token import
The text was updated successfully, but these errors were encountered: