https://github.com/wayou/print-chunks-plugin
webpack plugin to print chunks for bundle
https://github.com/wayou/print-chunks-plugin
debug print webpack webpack-plugin
Last synced: 5 days ago
JSON representation
webpack plugin to print chunks for bundle
- Host: GitHub
- URL: https://github.com/wayou/print-chunks-plugin
- Owner: wayou
- License: mit
- Created: 2018-02-02T13:27:48.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2022-12-29T08:20:25.000Z (almost 3 years ago)
- Last Synced: 2024-04-29T00:07:25.172Z (over 1 year ago)
- Topics: debug, print, webpack, webpack-plugin
- Language: JavaScript
- Homepage:
- Size: 104 KB
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 7
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# print-chunks-plugin
[](https://www.npmjs.com/package/print-chunks-plugin)
[](https://www.npmjs.com/package/print-chunks-plugin)Outputs exactly what went into each chunk
The code is taken from the [webpack documentation](https://github.com/webpack/docs/wiki/plugins#after-optimize-chunk-assetschunks-chunk)
I find this so useful for debugging. But there's no package in the npm.
### install
```
npm i -D print-chunks-plugin
```### usage
```js
var PrintChunksPlugin = require("print-chunks-plugin");
var webpackConfig = {
entry: "index.js",
output: {
path: __dirname + "/dist",
filename: "index_bundle.js",
},
plugins: [new PrintChunksPlugin()],
// or with option:
plugins: [new PrintChunksPlugin({ showFull: true })],
};
```### Options
- `showFull`: stringify the result to get rid of the 100 array output limit of `console.log`, [learn more](https://stackoverflow.com/questions/41669039/dumping-whole-array-console-log-and-console-dir-output-num-more-items)
- type: `bool`
- default: `false`