-
Notifications
You must be signed in to change notification settings - Fork 85
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Index.js makes some build tools think that it is a CommonJS module instead of ESM #55
Comments
+1, it looks like it prevents me from doing some tests with Jest. |
Just released v0.18.1 that should fix this. |
Thanks a lot for your great reactivity! I upgraded the package to 0.18.1 (and checked the associated package.json file in my node_modules folder, the module type is here) but I still have the error when running tests with Jest (but it's running fine otherwise). But here's my trace if it can help in any way:
|
In #42, this was traced down to jestjs/jest#2550 (comment). |
The index.js seems to be a CommonJS module to some build tools (notably Sveltekit's static adapter) because it does not have a .mjs suffix and there is no
"type": "module"
in the package.json. Two solutions are to add the module type to package.json, which would allow for the removal of all .mjs suffixes, or add an mjs suffix to index.js.The text was updated successfully, but these errors were encountered: