Skip to content

Commit ea53e69

Browse files
committed
Set up webpack-bundle-analyzer
1 parent ff4dcab commit ea53e69

File tree

3 files changed

+111
-1
lines changed

3 files changed

+111
-1
lines changed

package-lock.json

Lines changed: 107 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@
3333
"sass-loader": "^7.1.0",
3434
"style-loader": "^0.23.1",
3535
"webpack": "^4.23.1",
36+
"webpack-bundle-analyzer": "^3.0.3",
3637
"webpack-cli": "^3.1.2",
3738
"webpack-dev-server": "^3.1.10"
3839
},

webpack.config.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
const path = require('path');
22
const MiniCssExtractPlugin = require("mini-css-extract-plugin");
3+
const BundleAnalyzerPlugin = require('webpack-bundle-analyzer').BundleAnalyzerPlugin;
34

45
module.exports = {
56
devServer: {
@@ -37,7 +38,8 @@ module.exports = {
3738
new MiniCssExtractPlugin({
3839
filename: "[name].css",
3940
chunkFilename: "[id].css"
40-
})
41+
}),
42+
new BundleAnalyzerPlugin()
4143
],
4244
resolve: {
4345
extensions: ['.js', '.jsx']

0 commit comments

Comments
 (0)