-
-
Notifications
You must be signed in to change notification settings - Fork 6.3k
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
defaultModes error on build with node.js v12 #4014
Comments
Hello, thank you for taking time filling this issue! However, we kindly ask you to use our Issue Helper when creating new issues, in order to ensure every issue provides the necessary information for us to investigate. This explains why your issue has been automatically closed by me (your robot friend!). I hope to see your helper-created issue very soon! |
For anyone that finds this, this is the change in Node v12 that caused this error (for me at least). vue-cli is basically is trying to do
plugins = plugins.concat(files.map(file => ({
id: `local:${file}`,
apply: loadModule( file, this.pkgContext)
}))) Fixed: plugins = plugins.concat(files.map(file => ({
id: `local:${file}`,
apply: loadModule(`./${file}`, this.pkgContext)
}))) |
Thanks to @SneakyMax See vuejs#4014 (comment)
Thanks to @SneakyMax See #4014 (comment)
Thanks to @SneakyMax See #4014 (comment) (cherry picked from commit 78e1c4c)
Where is the file located in windows? |
Thanks to @SneakyMax See vuejs/vue-cli#4014 (comment)
Thanks to @SneakyMax See vuejs/vue-cli#4014 (comment)
@viruscamp - I get this error on build
` this.modes = this.plugins.reduce((modes, { apply: { defaultModes }}) => {
^
TypeError: Cannot destructure property
defaultModes
of 'undefined' or 'null'.at Service.modes.plugins.reduce (/opt/bluevine/node_modules/@vue/cli-service/lib/Service.js:37:48)
at Array.reduce ()
at new Service (/opt/bluevine/node_modules/@vue/cli-service/lib/Service.js:37:31)
at Object. (/opt/bluevine/node_modules/@vue/cli-service/bin/vue-cli-service.js:16:17)
at Module._compile (internal/modules/cjs/loader.js:689:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
at Module.load (internal/modules/cjs/loader.js:599:32)
at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
at Function.Module._load (internal/modules/cjs/loader.js:530:3)
at Function.Module.runMain (internal/modules/cjs/loader.js:742:12)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! deposit_accounts_dashboard@0.1.0 build:
vue-cli-service build
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the deposit_accounts_dashboard@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! /opt/bluevine/.npm/_logs/2019-02-01T02_29_03_707Z-debug.log`
Originally posted by @barakbd-bluevine in #2463 (comment)
For me I got the error by adding a custom vue service plugin in a node.js v12 environment. With node.js v10 it works perfect.
The text was updated successfully, but these errors were encountered: