A utility to integrate webpack-bundle-analyzer into Create React App configurations that use react-app-rewired (or react-scripts v1/v2). Version 1.1.0 (latest stable, updated in 2019) provides a simple wrapper that injects the BundleAnalyzerPlugin into the webpack config generated by CRA, with optional configuration passed directly to the plugin. It supports conditional activation based on environment (e.g., production only). Compared to alternatives like customize-cra or CRACO, this package is minimal and focused solely on bundle analysis. Note that it is not actively maintained and may not work with newer versions of CRA or webpack.
npm install react-app-rewire-webpack-bundle-analyzerNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Configures webpack-bundle-analyzer in a react-app-rewired config-overrides.js to generate a static HTML report during production build.
Switch to CRACO or customize-cra with webpack-bundle-analyzer plugin directly.
Always pass { analyzerMode: 'static', reportFilename: 'report.html' } for CI builds.Replace react-app-rewired with @craco/craco and use craco-bundle-analyzer plugin.
Double-check option spelling against webpack-bundle-analyzer docs.
Pin webpack-bundle-analyzer to ~3.0.0 in package.json.
npm install --save-dev react-app-rewire-webpack-bundle-analyzer
Use `const rewireWebpackBundleAnalyzer = require('react-app-rewire-webpack-bundle-analyzer')`Install react-app-rewired and ensure config-overrides.js exists in project root.
Upgrade to react-scripts >= 2.0.0 or use react-app-rewired with compatibility layers.