|
|
|
@ -1,4 +1,3 @@
|
|
|
|
|
/* eslint-disable filenames/match-exported */
|
|
|
|
|
const path = require('path');
|
|
|
|
|
const webpack = require('webpack');
|
|
|
|
|
const CopyPlugin = require('copy-webpack-plugin');
|
|
|
|
@ -7,11 +6,12 @@ const LiveReloadPlugin = require('webpack-livereload-plugin');
|
|
|
|
|
const MiniCssExtractPlugin = require('mini-css-extract-plugin');
|
|
|
|
|
const TerserPlugin = require('terser-webpack-plugin');
|
|
|
|
|
|
|
|
|
|
module.exports = (env) => {
|
|
|
|
|
const uiFolder = 'UI';
|
|
|
|
|
const frontendFolder = path.join(__dirname, '..');
|
|
|
|
|
const srcFolder = path.join(frontendFolder, 'src');
|
|
|
|
|
const isProduction = process.argv.indexOf('--production') > -1;
|
|
|
|
|
const isProfiling = isProduction && process.argv.indexOf('--profile') > -1;
|
|
|
|
|
const isProduction = !!env.production;
|
|
|
|
|
const isProfiling = isProduction && !!env.profile;
|
|
|
|
|
const inlineWebWorkers = 'no-fallback';
|
|
|
|
|
|
|
|
|
|
const distFolder = path.resolve(frontendFolder, '..', '_output', uiFolder);
|
|
|
|
@ -257,5 +257,5 @@ if (isProfiling) {
|
|
|
|
|
];
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
module.exports = config;
|
|
|
|
|
/* eslint-enable filenames/match-exported */
|
|
|
|
|
return config;
|
|
|
|
|
};
|
|
|
|
|