Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Error in gulp.js

Tags:

I tried to run gulp serve in my source directory. This command loaded all files and started to use my gulpfile.js.

As result I have the following error:

gulpInst.start.apply(gulpInst, toRun);
              ^

TypeError: Cannot read property 'apply' of undefined at C:\Users...\AppData\Roaming\npm\node_modules\gulp\bin\gulp.js:129:19 at nextTickCallbackWith0Args (node.js:420:9) at process._tickCallback (node.js:349:13) at Function.Module.runMain (module.js:443:11) at startup (node.js:139:18) at node.js:974:3

First line of gulpfile.js is:

const gulp = require('gulp');

It is my first experience with node.js and gulp too. I have got needing to start existing application from sources, and for me this error message looks like error in framework found by framework. I feel that I did something wrong, but do not know what? How can I fix this problem?

like image 358
Valentine Zakharenko Avatar asked Oct 24 '16 13:10

Valentine Zakharenko


1 Answers

Try to reinstall gulp-cli :

npm install -g gulp-cli
like image 70
Funereal Avatar answered Sep 23 '22 16:09

Funereal