mirror of
https://bitbucket.org/wisemapping/wisemapping-frontend.git
synced 2024-11-11 01:43:23 +01:00
32 lines
715 B
JavaScript
32 lines
715 B
JavaScript
const { merge } = require('webpack-merge');
|
|
const common = require('./webpack.common.js');
|
|
const path = require('path');
|
|
|
|
module.exports = merge(common, {
|
|
mode: 'production',
|
|
devtool: 'source-map',
|
|
output: {
|
|
filename: '[name].bundle.js',
|
|
path: path.resolve(__dirname, 'dist')
|
|
},
|
|
optimization: {
|
|
minimize: true,
|
|
usedExports: true,
|
|
splitChunks: {
|
|
cacheGroups: {
|
|
vendors: {
|
|
test: /node_modules\/(?!antd\/).*/,
|
|
name: "vendors",
|
|
chunks: "all",
|
|
},
|
|
// This can be your own design library.
|
|
antd: {
|
|
test: /node_modules\/(antd\/).*/,
|
|
name: "antd",
|
|
chunks: "all",
|
|
},
|
|
},
|
|
}
|
|
}
|
|
});
|