webpack-contrib / webpack-bundle-analyzer

Webpack plugin and CLI utility that represents bundle content as convenient interactive zoomable treemap
MIT License
12.56k stars 483 forks source link

No warning regarging accidenta webpack configuration settings that increase the bundle size dramatically (e.g. devtool: 'inline-source-map' ) #510

Closed gabriel-deliu closed 2 years ago

gabriel-deliu commented 2 years ago

Issue description

No warning regarging accidenta webpack configuration settings that increase the bundle size dramatically (e.g. devtool: 'inline-source-map' )

Details

We were investigating a significant bundle increase. Looking at the bundle diagram, we could not find anything suspicious. It turns out someone added "devtool: 'inline-source-map'" into the prod webpack config by mistake. It would be nice if you could check for the presence of inline source maps.

Technical info

"webpack": "5.67.0",
"webpack-bundle-analyzer": "4.5.0"
valscion commented 2 years ago

Hi! That sounds like a neat thing to have. However, it would require the plugin to start also analyzing the webpack configuration itself which it doesn't yet do.

Unfortunately this means this feature is currently out-of-scope for webpack-bundle-analyzer.

The idea however sounds like a useful webpack plugin or tool to exist as its own project 😊