本文整理汇总了TypeScript中gulp-watch.default函数的典型用法代码示例。如果您正苦于以下问题:TypeScript default函数的具体用法?TypeScript default怎么用?TypeScript default使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了default函数的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的TypeScript代码示例。
示例1: sequence
export = gulp.task('watch', () => {
const queue = sequence(300);
// Html
watch(paths.sources.index, queue.getHandler('development:html', 'favicons'));
// Styles
watch(paths.sources.styles, () => gulp.start('development:styles'));
});
示例2: watch
() => {
watch(paths.src.ts,
() => {
gulp.start('ts');
});
watch(paths.src.js,
() => {
gulp.start('js');
});
watch(paths.src.files,
() => {
gulp.start('files');
});
});
示例3: indexDirectory
gulp.task('index-level-generators', ()=> {
const indexLevelGenerators = ()=> indexDirectory('level-generators', ['!*.js', '*.tests.js']);
indexLevelGenerators();
watch(['level-generators/**/*.js', '!level-generators/index.js'], ()=> {
indexLevelGenerators();
});
});
示例4: watch
gulp.task('watch', () => {
watch({name: 'typescript', emitOnGlob: false, glob: './app/**/*.ts'}, () => {
gulp.start('typescript');
});
watch({name: 'templates', emitOnGlob: false, glob: ['./app/**/*.html', '!./app/index.html']}, () => {
gulp.start('templates');
});
watch({name: 'stylus', emitOnGlob: false, glob: './app/**/*.styl'}, () => {
gulp.start('stylus');
});
watch({name: 'index', emitOnGlob: false, glob: './app/index.html'}, () => {
gulp.start('index');
});
});
示例5:
gulp.task('copy-assets', ['bump'], () =>
[
gulp.src(['**', '!**.js', '!{node_modules,node_modules/**}'])
.pipe(watch(['**', '!**.js', '!{node_modules,node_modules/**}']))
.pipe(plumber())
.pipe(gulp.dest(`../npm-link/${dirName}/`)),
gulp.src(['**', '!**.js', '!{node_modules,node_modules/**}'])
.pipe(gulp.dest(`../npm-link/${dirName}/`))
]
示例6: watch
gulp.task('jspm:watch', function() {
return watch(config.watch, {verbose: true}, function() {
gulp.start('jspm:build');
});
});
示例7: watcher
function watcher() {
watch(pathsToTs, compileTs);
}