本文整理汇总了TypeScript中gulp.start函数的典型用法代码示例。如果您正苦于以下问题:TypeScript start函数的具体用法?TypeScript start怎么用?TypeScript start使用的例子?那么, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了start函数的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的TypeScript代码示例。
示例1: e2eWatch
function e2eWatch(componentName: string, componentTest: string) {
// If any tests change within components then run e2e.resources.
watch([
'src/components/*/test/**/*'
],
function (file) {
console.log('start e2e.resources - ' + JSON.stringify(file.history, null, 2));
start('e2e.copyAndCompile');
});
// If any src files change except for tests then transpile only the source ionic files
watch([
'src/**/*.ts',
'!src/components/*/test/**/*',
'!src/util/test/*'
],
function (file) {
console.log('start e2e.ngcSource - ' + JSON.stringify(file.history, null, 2));
start('e2e.copyAndCompile');
});
// If any scss files change then recompile all sass
watch(['src/**/*.scss'], (file) => {
console.log('start sass - ' + JSON.stringify(file.history, null, 2));
start('e2e.sass');
});
console.log(`http://localhost:${LOCAL_SERVER_PORT}/${DIST_NAME}/${E2E_NAME}/components/${componentName}/test/${componentTest}/`);
start('e2e.serve');
}
示例2: watchTask
function watchTask(task) {
watch([
'src/**/*.ts',
'!src/components/*/test/**/*',
'!src/util/test/*'
],
function (file) {
if (file.event !== 'unlink') {
start(task);
}
}
);
watch('src/**/*.scss', function () {
start('e2e.sass');
});
start('e2e.serve');
}
示例3: demosWatch
function demosWatch(componentName: string, componentTest: string) {
// If any tests change within components then run demos.resources.
watch([
'demos/src/**/*'
],
function (file) {
console.log('start demos.resources - ' + JSON.stringify(file.history, null, 2));
start('demos.copyAndCompile');
});
// If any src files change except for tests then transpile only the source ionic files
watch([
'src/**/*.ts',
'!src/components/*/test/**/*',
'!src/util/test/*'
],
function (file) {
console.log('start demos.ngcSource - ' + JSON.stringify(file.history, null, 2));
start('demos.copyAndCompile');
});
// If any scss files change then recompile all sass
watch(['src/**/*.scss'], (file) => {
console.log('start sass - ' + JSON.stringify(file.history, null, 2));
start('demos.sass');
});
let serverUrl = `http://localhost:${LOCAL_SERVER_PORT}/${DIST_NAME}/${DEMOS_NAME}`;
if (componentName) {
serverUrl += `/${componentName}`;
}
console.log(serverUrl);
start('demos.serve');
}
示例4: function
function (file) {
console.log('start e2e.resources - ' + JSON.stringify(file.history, null, 2));
start('e2e.copyAndCompile');
});
示例6: watch
watch('src/**/*.scss', function () {
start('e2e.sass');
});
示例7: watch
watch({name: 'templates', emitOnGlob: false, glob: ['./app/**/*.html', '!./app/index.html']}, () => {
gulp.start('templates');
});
示例8: function
function (file) {
if (file.event !== 'unlink') {
start(task);
}
}