在Laravel Project中运行Gulp时安装VueJS
,我得到以下信息:
Me-MBP:simpleb2b AdnanAhmad$ gulp build
/Applications/MAMP/htdocs//myProject//node_modules/laravel-elixir-vue/main.js:4
Elixir.webpack.mergeConfig({
^
TypeError: Cannot read property 'mergeConfig' of undefined
at /Applications/MAMP/htdocs//myProject/node_modules/laravel-elixir-vue/main.js:4:19
at /Applications/MAMP/htdocs//myProject//node_modules/laravel-elixir/dist/index.js:29:16
at Array.forEach (native)
at global.Elixir (/Applications/MAMP/htdocs//myProject//node_modules/laravel-elixir/dist/index.js:28:24)
at Object.<anonymous> (/Applications/MAMP/htdocs//myProject//gulpfile.js:16:1)
at Module._compile (module.js:541:32)
at Object.Module._extensions..js (module.js:550:10)
at Module.load (module.js:458:32)
at tryModuleLoad (module.js:417:12)
at Function.Module._load (module.js:409:3)
答案 0 :(得分:0)
此问题通过运行npm install并使用git-bash cmd运行gulp来解决我的问题。 注意:请确保按照建议的here
全局安装gulp答案 1 :(得分:0)
删除和重建\node_modules
并没有为我改变任何内容。
尝试
npm install --save laravel-elixir-webpack-official
此后应该有效。