Gulp命令不适用于laravel

时间:2015-12-08 13:08:32

标签: php laravel npm gulp

最初我安装了node.js和npm。

使用npm我安装了gulp:sudo npm install -g gulp

这是输出:

/var/www/html/laravel$ gulp

Error: Cannot find module 'process-nextick-args'
    at Function.Module._resolveFilename (module.js:338:15)
    at Function.Module._load (module.js:280:25)
    at Module.require (module.js:364:17)
    at require (module.js:380:17)
    at Object.<anonymous> (/var/www/html/laravel/node_modules/laravel-elixir/node_modules/gulp-util/node_modules/through2/node_modules/readable-stream/lib/_stream_duplex.js:20:23)
    at Module._compile (module.js:456:26)
    at Object.Module._extensions..js (module.js:474:10)
    at Module.load (module.js:356:32)
    at Function.Module._load (module.js:312:12)
    at Module.require (module.js:364:17)

1 个答案:

答案 0 :(得分:3)

您应该在运行gulp之前安装所有npm deps。从项目文件夹中运行:

{{1}}