mirror of
https://github.com/sourcegraph/sourcegraph.git
synced 2026-02-06 17:11:49 +00:00
* web: add CSS-modules support to web-app and Storybook * web: hey prettier * web: hey stylelint * web: cleanup style tag in BrandedStory * web: add CSS modules config to browser package * web: keep localIndentName consistent between NODE_ENV * web: add JSDoc and description to `getCSSLoaders` * web: add CSS modules docs to web/styling.md * web: use standalone TS types generator for CSS modules * web: updated web/styling.md * web: extract new generate commands into a separate files * web: let Gulp understand when we are done * web: fix bin issue * web: fix bin issue [2] * web: update generateCssModulesTypes * update web/styling.md Co-authored-by: Felix Becker <felix.b@outlook.com> * update web/styling.md Co-authored-by: Felix Becker <felix.b@outlook.com> * update web/styling.md Co-authored-by: Tom Ross <tom@umpox.com> * web: simplify CSS selectors for PageSelector component * web: updated web/styling.md * web: make config consistent again Co-authored-by: Felix Becker <felix.b@outlook.com> Co-authored-by: Tom Ross <tom@umpox.com>
52 lines
1.2 KiB
JavaScript
52 lines
1.2 KiB
JavaScript
// @ts-check
|
|
|
|
const gulp = require('gulp')
|
|
const {
|
|
graphQlSchema,
|
|
graphQlOperations,
|
|
schema,
|
|
watchGraphQlSchema,
|
|
watchGraphQlOperations,
|
|
watchSchema,
|
|
cssModulesTypings,
|
|
watchCSSModulesTypings,
|
|
} = require('./client/shared/gulpfile')
|
|
const { webpack: webWebpack, webpackDevServer: webWebpackDevServer } = require('./client/web/gulpfile')
|
|
|
|
/**
|
|
* Generates files needed for builds.
|
|
*/
|
|
const generate = gulp.parallel(schema, graphQlSchema, graphQlOperations, cssModulesTypings)
|
|
|
|
/**
|
|
* Starts all watchers on schema files.
|
|
*/
|
|
const watchGenerators = gulp.parallel(watchSchema, watchGraphQlSchema, watchGraphQlOperations, watchCSSModulesTypings)
|
|
|
|
/**
|
|
* Generates files needed for builds whenever files change.
|
|
*/
|
|
const watchGenerate = gulp.series(generate, watchGenerators)
|
|
|
|
/**
|
|
* Builds everything.
|
|
*/
|
|
const build = gulp.series(generate, webWebpack)
|
|
|
|
/**
|
|
* Watches everything and rebuilds on file changes.
|
|
*/
|
|
const dev = gulp.series(generate, gulp.parallel(watchGenerators, webWebpackDevServer))
|
|
|
|
module.exports = {
|
|
generate,
|
|
watchGenerate,
|
|
build,
|
|
dev,
|
|
schema,
|
|
graphQlSchema,
|
|
watchGraphQlSchema,
|
|
graphQlOperations,
|
|
watchGraphQlOperations,
|
|
}
|