加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
gulpfile.js 989 Bytes
一键复制 编辑 原始数据 按行查看 历史
Mimi St Johns 提交于 2020-08-06 10:58 . upadte
// @ts-check
const gulp = require('gulp')
const {
graphQlSchema,
graphQlOperations,
schema,
watchGraphQlSchema,
watchGraphQlOperations,
watchSchema,
} = require('./shared/gulpfile')
const { webpack: webWebpack, webpackDevServer: webWebpackDevServer } = require('./web/gulpfile')
/**
* Generates files needed for builds.
*/
const generate = gulp.parallel(schema, graphQlSchema, graphQlOperations)
/**
* Generates files needed for builds whenever files change.
*/
const watchGenerate = gulp.series(generate, gulp.parallel(watchSchema, watchGraphQlSchema, watchGraphQlOperations))
/**
* Builds everything.
*/
const build = gulp.series(generate, webWebpack)
/**
* Watches everything and rebuilds on file changes.
*/
const watch = gulp.series(generate, gulp.parallel(watchGenerate, webWebpackDevServer))
module.exports = {
generate,
watchGenerate,
build,
watch,
schema,
graphQlSchema,
watchGraphQlSchema,
graphQlOperations,
watchGraphQlOperations,
}
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化