mirror of https://github.com/webpack/webpack.git
26 lines
617 B
JavaScript
26 lines
617 B
JavaScript
"use strict";
|
|
|
|
const path = require("path");
|
|
const webpack = require("../../");
|
|
|
|
module.exports = {
|
|
// mode: "development" || "production",
|
|
cache: true, // better performance for the AggressiveSplittingPlugin
|
|
entry: "./example",
|
|
output: {
|
|
path: path.join(__dirname, "dist"),
|
|
filename: "[chunkhash].js",
|
|
chunkFilename: "[chunkhash].js"
|
|
},
|
|
plugins: [
|
|
new webpack.optimize.AggressiveSplittingPlugin({
|
|
minSize: 30000,
|
|
maxSize: 50000
|
|
}),
|
|
new webpack.DefinePlugin({
|
|
"process.env.NODE_ENV": JSON.stringify("production")
|
|
})
|
|
],
|
|
recordsOutputPath: path.join(__dirname, "dist", "records.json")
|
|
};
|