How to use magix-combine - 10 common examples

To help you get started, we’ve selected a few magix-combine examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github thx / magix-gallery / gulpfile.js View on Github external
gulp.task('combine', ['cleanDir', 'chartpark'], async () => {
    await spawnCommand('gulp', ['rely']);

    combineTool.config({
        tmplFolder: 'tmpl',
        srcFolder: 'build/src'
    })
    return combineTool.combine().then(() => {
        console.log('complete');
    }).catch(ex => {
        console.log('gulpfile:', ex);
    });
});
github thx / magix / project / gulpfile.js View on Github external
watch(tmplFolder + '/**/*', function(e) {
        console.log(e.path);
        if (path.extname(e.path) == '.scss') {
            if (config.incrementBuild) {
                return gulp.src([e.path])
                    .pipe($.sass().on('error', $.sass.logError))
                    .pipe($.autoprefixer(autoPrefixerConfig))
                    .pipe(gulp.dest(path.dirname(e.path)));
            } else {
                runSequence('sass');
            }
            return;
        }
        if (fs.existsSync(e.path)) {
            combineTool.processFile(e.path);
        } else {
            combineTool.removeFile(e.path);
        }
    });
});
github xinglie / game-diamond / gulpfile.js View on Github external
watch(tmplFolder + '/**/*', function(e) {
        console.log(e.path);
        if (fs.existsSync(e.path)) {
            combineTool.processFile(e.path);
        } else {
            combineTool.removeFile(e.path);
        }
    });
});
github thx / magix / doc / gulpfile.js View on Github external
watch(tmplFolder + '/**/*', function(e) {
        console.log(e.path);
        if (fs.existsSync(e.path)) {
            combineTool.processFile(e.path);
        } else {
            combineTool.removeFile(e.path);
        }
    });
});
github thx / magix-gallery / gulpfile.js View on Github external
watch('./tmpl/**/*', e => {
        if (fs.existsSync(e.path)) {
            combineTool.processFile(e.path).catch(ex => {
                console.log('ex', ex);
            });
        } else {
            combineTool.removeFile(e.path);
        }
    });
});
github xinglie / game-diamond / gulpfile.js View on Github external
watch(tmplFolder + '/**/*', function(e) {
        console.log(e.path);
        if (fs.existsSync(e.path)) {
            combineTool.processFile(e.path);
        } else {
            combineTool.removeFile(e.path);
        }
    });
});
github thx / magix-gallery / gulpfile.js View on Github external
watch('./tmpl/**/*', e => {
        if (fs.existsSync(e.path)) {
            combineTool.processFile(e.path).catch(ex => {
                console.log('ex', ex);
            });
        } else {
            combineTool.removeFile(e.path);
        }
    });
});
github thx / magix / project / gulpfile.js View on Github external
console.log(e.path);
        if (path.extname(e.path) == '.scss') {
            if (config.incrementBuild) {
                return gulp.src([e.path])
                    .pipe($.sass().on('error', $.sass.logError))
                    .pipe($.autoprefixer(autoPrefixerConfig))
                    .pipe(gulp.dest(path.dirname(e.path)));
            } else {
                runSequence('sass');
            }
            return;
        }
        if (fs.existsSync(e.path)) {
            combineTool.processFile(e.path);
        } else {
            combineTool.removeFile(e.path);
        }
    });
});
github thx / magix / doc / gulpfile.js View on Github external
watch(tmplFolder + '/**/*', function(e) {
        console.log(e.path);
        if (fs.existsSync(e.path)) {
            combineTool.processFile(e.path);
        } else {
            combineTool.removeFile(e.path);
        }
    });
});
github thx / magix-gallery / gulpfile.js View on Github external
gulp.task('rely', () => {
    combineTool.config({
        log: false,
        tmplFolder: 'dist',
        srcFolder: 'build'
    })
    return combineTool.combine().then(() => {
        console.log('complete');
    }).catch(ex => {
        console.log('gulpfile:', ex);
    });
});

magix-combine

合并Magix View的html,js,css成一个js文件,并检测html,js,css中可能存在的问题

MIT
Latest version published 19 days ago

Package Health Score

57 / 100
Full package analysis