我得到一個錯誤我想不出在使用gulpJs模塊一飲而盡玉Gulpjs - 吞掉玉編譯問題
> [11:13:59] TypeError: listener must be a function
> at DestroyableTransform.addListener (events.js:197:11)
> at DestroyableTransform.Readable.on (/Users/ME/Sites/temp/node_modules/through2/node_modules/readable-stream/lib/_stream_readable.js:718:33)
> at Gulp.<anonymous> (/Users/ME/Sites/temp/gulpfile.js:14:16)
> at module.exports (/Users/ME/Sites/temp/node_modules/orchestrator/lib/runTask.js:34:7)
> at Gulp.Orchestrator._runTask (/Users/ME/Sites/temp/node_modules/orchestrator/index.js:273:3)
> at Gulp.Orchestrator._runStep (/Users/ME/Sites/temp/node_modules/orchestrator/index.js:214:10)
> at Gulp.Orchestrator.start (/Users/ME/Sites/temp/node_modules/orchestrator/index.js:134:8)
> at /usr/local/lib/node_modules/gulp/bin/gulp.js:129:20
> at doNTCallback0 (node.js:428:9)
> at process._tickCallback (node.js:357:13)
我已經正確安裝了模塊和我gulpfile是:
var gulp = require('gulp');
var jade = require('gulp-jade');
gulp.task('markup', function() {
gulp.src('jade/**/*.jade')
.pipe(jade().on('error', jade.logError))
.pipe(gulp.dest('/build'));
});
那麼'jade.logError'不是一個函數? – robertklep