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

TypeError: Cannot read property 'javascript' of undefined #339

Closed
WangSuwen opened this issue Oct 19, 2020 · 3 comments
Closed

TypeError: Cannot read property 'javascript' of undefined #339

WangSuwen opened this issue Oct 19, 2020 · 3 comments

Comments

@WangSuwen
Copy link

I got a problem:TypeError: Cannot read property 'javascript' of undefined , and i don`t know how to fix it...

@WangSuwen
Copy link
Author

ERROR TypeError: Cannot read property 'javascript' of undefined
TypeError: Cannot read property 'javascript' of undefined
at compiler.hooks.compilation.tap.compilation (/Users/wxq/workspace//frontweb/node_modules/terser-webpack-plugin/dist/index.js:366:38)
at SyncHook.eval [as call] (eval at create (/Users/wxq/workspace//frontweb/node_modules/tapable/lib/HookCodeFactory.js:19:10), :97:1)
at SyncHook.lazyCompileHook (/Users/wxq/workspace//frontweb/node_modules/tapable/lib/Hook.js:154:20)
at Compiler.newCompilation (/Users/wxq/workspace//frontweb/node_modules/webpack/lib/Compiler.js:631:26)
at hooks.beforeCompile.callAsync.err (/Users/wxq/workspace//frontweb/node_modules/webpack/lib/Compiler.js:667:29)
at AsyncSeriesHook.eval [as callAsync] (eval at create (/Users/wxq/workspace//frontweb/node_modules/tapable/lib/HookCodeFactory.js:33:10), :6:1)
at AsyncSeriesHook.lazyCompileHook (/Users/wxq/workspace/frontweb/node_modules/tapable/lib/Hook.js:154:20)
at Compiler.compile (/Users/wxq/workspace/xx/frontweb/node_modules/webpack/lib/Compiler.js:662:28)
at readRecords.err (/Users/wxq/workspace/xx/frontweb/node_modules/webpack/lib/Compiler.js:321:11)
at Compiler.readRecords (/Users/wxq/workspace/xx/frontweb/node_modules/webpack/lib/Compiler.js:529:11)
at hooks.run.callAsync.err (/Users/wxq/workspace/xx/frontweb/node_modules/webpack/lib/Compiler.js:318:10)
at AsyncSeriesHook.eval [as callAsync] (eval at create (/Users/wxq/workspace/xx/frontweb/node_modules/tapable/lib/HookCodeFactory.js:33:10), :6:1)
at AsyncSeriesHook.lazyCompileHook (/Users/wxq/workspace/xx/frontweb/node_modules/tapable/lib/Hook.js:154:20)
at hooks.beforeRun.callAsync.err (/Users/wxq/workspace/xx/frontweb/node_modules/webpack/lib/Compiler.js:315:19)
at AsyncSeriesHook.eval [as callAsync] (eval at create (/Users/wxq/workspace/xx/frontweb/node_modules/tapable/lib/HookCodeFactory.js:33:10), :15:1)
at AsyncSeriesHook.lazyCompileHook (/Users/wxq/workspace/xx/frontweb/node_modules/tapable/lib/Hook.js:154:20)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! frontweb@0.1.0 build: vue-cli-service build --mode production
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the frontweb@0.1.0 build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR! /Users/wxq/.npm/_logs/2020-10-19T06_39_53_019Z-debug.log

@alexander-akait
Copy link
Member

alexander-akait commented Oct 19, 2020

v5 don't support webpack@4, use v4 for webpack@4, please use the issue template, respect time of other developers, thanks

@Etienereum
Copy link

Was having similar issue, because I was using some dependencies also in the devDependencies but with different versions in my package.json file.

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

3 participants