this.emit('error', new gutil.PluginError('gulp-jscs', out.join('\n\n'), {
^RangeError:字符串长度无效
at Array.join (native)
at DestroyableTransform._flush (C:\ABC\node_modules\gulp-jscs\index.j
s:99:62)
at DestroyableTransform.<anonymous> (C:\ABC\node_modules\gulp-jscs\no
de_modules\through2\node_modules\readable-stream\lib\_stream_transform.js:135:12
)发布于 2016-02-16 12:59:08
添加try & catch块函数, (cb) {
if (out.length > 0) {
try {
console.log('out is: ', out[1]);
this.emit('error', new gutil.PluginError('gulp-jscs', out.join('\n\n'), {
showStack: false
}));
} catch (e) {
console.log('exception: ', e);
}
}
cb();
})https://stackoverflow.com/questions/35423905
复制相似问题