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

webpack warning: Critical dependency: require function is used in a way in which dependencies cannot be statically extracted #117

Open
bikramtuladhar opened this issue Oct 19, 2022 · 1 comment

Comments

@bikramtuladhar
Copy link

i'm using webpack 5 getting warning

WARNING in ./node_modules/vue-nl2br/dist/Nl2br.js 3:24-31
Critical dependency: require function is used in a way in which dependencies cannot be statically extracted

Couldn't figure it out why it's not working.

@drone076
Copy link

Fork this repo, change this line in the tsconfig.json

"module": "umd",

  • replace "umd" with "commonjs". And then recompile project: npm i && npm run build

Webpack is unable to process umd module. Hope this helps

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

2 participants