webpack-stats-report
Webpack Stats Report
Preview Example Reports
Install
npm i webpack-stats-report -D
Usage
As a webpack plugin
// webpack.config.js
const StatsReportPlugin = require("webpack-stats-report").StatsReportPlugin;
module.exports = {
// ... configuration settings here ...
plugins: [new StatsReportPlugin({
//options
title: "Stats Report - webpack-stats-report",
output: ".temp/stats-report.html"
})]
};
As a Node API
const webpack = require('webpack');
const StatsReportGenerator = require("webpack-stats-report").StatsReportGenerator;
webpack(webpackConfig, async (err, stats) => {
await StatsReportGenerator({
//options
title: "Stats Report - webpack-stats-report",
output: ".temp/stats-report.html",
//require one more option stats
stats: stats.toJson({
//source for gzipSize = true
source: true,
reasons: false,
chunkModules: false
})
});
});
Options
//default options
{
title: "Stats Report",
output: "stats-report.html",
outputStatsJson: false,
gzipSize: false
...
}
more details: options.js
Test
npm run test
see test/test.js
Changelog
see CHANGELOG.md
Version History
| Version | Released | Vue | License |
|---|---|---|---|
| 2.0.6 | ^3.3.7 | MIT | |
| 2.0.5 | ^3.3.4 | MIT | |
| 2.0.4 | ^3.2.47 | MIT | |
| 2.0.3 | ^3.2.40 | ||
| 2.0.2 | ^3.2.37 | ||
| 2.0.1 | ^3.2.37 | ||
| 2.0.0 | ^3.2.36 | ||
| 1.2.4 | |||
| 1.2.3 | |||
| 1.2.2 | |||
| 1.2.1 | |||
| 1.2.0 | |||
| 1.1.10 | |||
| 1.1.9 | |||
| 1.1.8 | |||
| 1.1.7 | |||
| 1.1.6 | |||
| 1.1.5 | |||
| 1.1.4 | |||
| 1.1.3 | |||
| 1.1.2 | |||
| 1.1.1 | ^2.6.11 | ||
| 1.1.0 | ^2.6.11 | ||
| 1.0.3 | |||
| 1.0.2 | |||
| 1.0.1 | |||
| 1.0.0 |