本文整理汇总了TypeScript中del类的典型用法代码示例。如果您正苦于以下问题:TypeScript del类的具体用法?TypeScript del怎么用?TypeScript del使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了del类的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的TypeScript代码示例。
示例1: async
gulp.task("cov:instrument", async () => {
del(coverageRootPath);
del(nycOutputPath);
return spawnNode([
nycPath,
'instrument',
'--require',
'source-map-support/register',
'.',
'.'
], {
cwd: codeExtensionSourcesPath
});
});
示例2: task
task('clean.src', (done: Function) => {
del(['src/**/*.js', 'src/**/*.d.ts', '!src/components/slides/swiper-widget.*']).then(() => {
done();
}).catch(err => {
done(err);
});
});
示例3: mv
mv(copyInst.from, copyInst.toSrc, {mkdirp: true}, (err?) => {
if (err) {
reject(err);
} else {
resolve(del(p));
}
});
示例4: task
task('demos.clean', (done: Function) => {
del([`${DIST_DEMOS_ROOT}/**`]).then(() => {
done();
}).catch(err => {
done(err);
});
});
示例5: cleanAppDev
function cleanAppDev(done) {
del([
join(PATH.dest.dev.all, '**/*'),
'!' + PATH.dest.dev.lib,
'!' + join(PATH.dest.dev.lib, '*')
], done);
}
示例6: task
task('clean.src', (done: Function) => {
del(['src/**/*.js', 'src/**/*.d.ts']).then(() => {
done();
}).catch(err => {
done(err);
});
});
示例7: clean
// delete everything used in our test cycle here
function clean(): any {
'use strict';
// You can use multiple globbing patterns as you would with `gulp.src`
return del([DIST_DIR + '**/*', '!' + TEST_DIST, RELEASE_DIR + '**/*']).then((paths: Array<any>) => {
util.log('Deleted', chalk.yellow(paths && paths.join(', ') || '-'));
});
}
示例8: del
const clean = (): Promise<string[]> => {
return del([
'./www',
'./dist',
'./.tmp'
]).then((value) => {
return value
})
}
示例9: Promise
return new Promise((resolve, reject) => {
del(['.build/'], (err: any) => {
if (err) {
reject(err);
} else {
resolve();
}
});
});