1
我正在分析VS代碼測試。.once(string,function)是做什麼的?
'use strict';
const gulp = require('gulp');
const mocha = require('gulp-mocha');
gulp.task('test', function() {
return gulp.src('test/all.js')
.pipe(mocha({ ui: 'tdd', delay: true }))
.once('end', function() { process.exit(); });
});
我還未找到任何關於once(string, function)
的文檔。它有什麼作用?文檔在哪裏?
Having searched the gulp source揭示了使用但未定義一次。