Hi,
First of all thanks for laravel-mix. However I can't get it to work.
My steps:
npm installnode and npm to latest versionslaravel-mix to 0.5.1webpack.mix.js to match the fix branch on the Laravel repoEvery time I run npm run dev I get the below error. Any idea what it could be?
Full stack trace:
npm verb lifecycle @~dev: unsafe-perm in lifecycle true
npm verb lifecycle @~dev: PATH: /usr/local/lib/node_modules/npm/bin/node-gyp-bin:/Users/bobbybouwmann/OpenSource/vault/node_modules/.bin:/Users/bobbybouwmann/.composer/vendor/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/MacGPG2/bin:/Users/bobbybouwmann/.composer/vendor/bin
npm verb lifecycle @~dev: CWD: /Users/bobbybouwmann/OpenSource/vault
npm info lifecycle @~dev: Failed to exec dev script
npm verb stack Error: @ dev: `cross-env NODE_ENV=development webpack --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js`
npm verb stack Exit status 2
npm verb stack at EventEmitter.<anonymous> (/usr/local/lib/node_modules/npm/lib/utils/lifecycle.js:279:16)
npm verb stack at emitTwo (events.js:106:13)
npm verb stack at EventEmitter.emit (events.js:191:7)
npm verb stack at ChildProcess.<anonymous> (/usr/local/lib/node_modules/npm/lib/utils/spawn.js:40:14)
npm verb stack at emitTwo (events.js:106:13)
npm verb stack at ChildProcess.emit (events.js:191:7)
npm verb stack at maybeClose (internal/child_process.js:885:16)
npm verb stack at Process.ChildProcess._handle.onexit (internal/child_process.js:226:5)
npm verb pkgid @
npm verb cwd /Users/bobbybouwmann/OpenSource/vault
npm ERR! Darwin 15.6.0
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "run" "dev" "--verbose"
npm ERR! node v7.4.0
npm ERR! npm v4.1.1
npm ERR! code ELIFECYCLE
npm ERR! @ dev: `cross-env NODE_ENV=development webpack --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js`
npm ERR! Exit status 2
npm ERR!
npm ERR! Failed at the @ dev script 'cross-env NODE_ENV=development webpack --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! cross-env NODE_ENV=development webpack --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls
npm ERR! There is likely additional logging output above.
npm verb exit [ 1, true ]
npm ERR! Please include the following file with any support request:
npm ERR! /Users/bobbybouwmann/OpenSource/vault/npm-debug.log
What version of Node and NPM do you have installed?
npm ERR! node v7.4.0 npm ERR! npm v4.1.1
:wink:
Thanks.
I can't reproduce this. Bobby, what does your webpack.mix.js file look like? Have you changed it at all? Are you in a VM here?
Thanks for coming back to this. I actually figured out what went wrong... I had bootstrap-sass and bootstrap-4 alpha installed and that gave issues, because it didn't know which bootstrap to pick on the javascript side and that broke stuff.
Anyway thanks for taking a look at this!
i try update node, npm to latest
node v7.9.0
npm v4.2.0
but not working
and then i added _babel-preset-es2015_ => it working 馃拑
this command:
npm install --save-dev babel-cli babel-preset-es2015
npm install babel-loader babel-core babel-preset-env webpack --save-dev
I hope, i can help someone!
Thanks @ngankt2
Most helpful comment
i try update node, npm to latest
but not working
and then i added _babel-preset-es2015_ => it working 馃拑
this command:
I hope, i can help someone!