mirror of
https://github.com/gristlabs/grist-core.git
synced 2026-03-02 04:09:24 +00:00
Use chokidar to bundle css files
This commit is contained in:
@@ -19,3 +19,4 @@ buildtools/update_type_info.sh app
|
||||
webpack --config $WEBPACK_CONFIG --mode production
|
||||
webpack --config buildtools/webpack.check.js --mode production
|
||||
webpack --config buildtools/webpack.api.config.js --mode production
|
||||
cat app/client/*.css app/client/*/*.css > static/bundle.css
|
||||
|
||||
@@ -1,11 +1,7 @@
|
||||
const fs = require('fs');
|
||||
const MomentLocalesPlugin = require('moment-locales-webpack-plugin');
|
||||
const MergeIntoSingleFilePlugin = require('webpack-merge-and-include-globally');
|
||||
const { ProvidePlugin } = require('webpack');
|
||||
const path = require('path');
|
||||
const glob = require('glob');
|
||||
|
||||
const cssFiles = glob.sync('app/client/**/*.css');
|
||||
|
||||
// Get path to top-level node_modules if in a yarn workspace.
|
||||
// Otherwise node_modules one level up won't get resolved.
|
||||
@@ -21,7 +17,6 @@ module.exports = {
|
||||
boot: "app/client/boot",
|
||||
billing: "app/client/billingMain",
|
||||
form: "app/client/formMain",
|
||||
css: new Set(cssFiles),
|
||||
// Include client test harness if it is present (it won't be in
|
||||
// docker image).
|
||||
...(fs.existsSync("test/client-harness/client.js") ? {
|
||||
@@ -92,12 +87,6 @@ module.exports = {
|
||||
process: 'process',
|
||||
Buffer: ['buffer', 'Buffer']
|
||||
}),
|
||||
new MergeIntoSingleFilePlugin({
|
||||
files: {
|
||||
"bundle.css": cssFiles
|
||||
},
|
||||
chunks: "css"
|
||||
}),
|
||||
// To strip all locales except “en”
|
||||
new MomentLocalesPlugin()
|
||||
],
|
||||
|
||||
Reference in New Issue
Block a user