Skip to content
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

Incorrect 'module' in package.json #206

Open
CrabSAMA opened this issue Jul 4, 2023 · 0 comments
Open

Incorrect 'module' in package.json #206

CrabSAMA opened this issue Jul 4, 2023 · 0 comments

Comments

@CrabSAMA
Copy link

CrabSAMA commented Jul 4, 2023

"module": "dist/vue-i18n-extract.modern.js",

This line is incorrect, in dist I found vue-i18n-extract.modern.mjs but now module is vue-i18n-extract.modern.js. It will get some questions when bundling it with rollup or vite.

when using rollup:

(!) Unresolved dependencies
https://rollupjs.org/troubleshooting/#warning-treating-module-as-external-dependency
vue-i18n-extract (imported by "src/index.ts")

rollup can bundle success, but it will not bundle vue-i18n-extract to the building.

when using vite:

[commonjs--resolver] Failed to resolve entry for package "vue-i18n-extract". The package may have incorrect main/module/exports specified in its package.json.
error during build:
Error: Failed to resolve entry for package "vue-i18n-extract". The package may have incorrect main/module/exports specified in its package.json.

using vite bundle will throw an error and the build fails.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant