-
-
Notifications
You must be signed in to change notification settings - Fork 6.6k
Open
Labels
Description
Version
30.0.5, also reproduced with 29.7.0
EDIT :
With the suggestions provided by @hainenber , it is now a windows-only problem. It works fine in WSL. It still is a problem.
Steps to reproduce
- Clone my reproduction repo
- run
npm ci
to install dependencies - run
npm run test
- Error comes up : "SyntaxError : Cannot use import statement outside a module"
Expected behavior
the package @vueuse/core should be transformed, according to the value of transformIgnorePatterns
in jest.config.js.
Actual behavior
Jest fails with SyntaxError when importing @vueuse/core` It works in the other test when importing loadash
Additional context
I reproduces babel and jest configurations from the project I work on, but all with the latest versions.
Maybe related to issue #15728 ?
Environment
System:
OS: Windows 11
Binairies:
node: 22.16.0
npm: 11.4.1
npmPackages:
@babel/plugin-transform-runtime: 7.28.0
@babel/preset-env: 7.28.0
@babel/runtime-corejs3: 7.28.2
@vueuse/core: 13.6.0
babel-jest: 30.0.5
jest-environment-jsdom: 30.0.5
jest: 30.0.5
lodash: 4.17.21
Also with the same npmPackages on WSL2
System:
OS: 6.6.87.2-microsoft-standard-WSL2
Binairies:
node: 22.18.0
npm: 11.5.2