-
-
Notifications
You must be signed in to change notification settings - Fork 451
Closed
Description
I'm submitting a bug report
Babel Loader Version:
9.1.13
Please tell us about your environment:
n/a
Current behavior:
Package contains ES6 import. Introduced recently in this PR: https://github.com/babel/babel-loader/pull/995/files#diff-3fb1021e8b65be53e466751de219baf5282edb86a3a1ad8fe429cac948991af7R16
Caused by upgrading find-cache-dir
from v4 to v5.
Using Webpack build inside Jest tests is failing.
You need to run with a version of node that supports ES Modules in the VM API. See https://jestjs.io/docs/ecmascript-modules
at invariant (node_modules/jest-util/build/invariant.js:16:11)
at Object.<anonymous> (node_modules/babel-loader/lib/cache.js:22:23)
Expected/desired behavior:
Either new breaking change version, or reverting find-cache-dir
upgrade.
- If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem along with a gist/jsbin of your webpack configuration.
Simple example https://codesandbox.io/p/devbox/babel-loader-jest-rmkkd2?file=%2Fpackage.json
npm run test
Schweinepriester, goncharov, 7rulnik, XueMeijing and glen-cheney
Metadata
Metadata
Assignees
Labels
No labels