CARVIEW |
Select Language
HTTP/2 301
date: Fri, 25 Jul 2025 19:53:06 GMT
content-type: text/html
content-length: 162
location: https://webpack.js.org/plugins/limit-chunk-count-plugin/
nel: {"report_to":"cf-nel","success_fraction":0.0,"max_age":604800}
server: cloudflare
access-control-allow-origin: *
expires: Fri, 25 Jul 2025 20:03:06 GMT
cache-control: max-age=600
x-proxy-cache: MISS
x-github-request-id: 9507:96B1:8AE1:AB25:6883E0A0
accept-ranges: bytes
age: 0
via: 1.1 varnish
x-served-by: cache-maa10234-MAA
x-cache: MISS
x-cache-hits: 0
x-timer: S1753473186.448964,VS0,VE225
vary: Accept-Encoding
x-fastly-request-id: 0931d3344501903ffb60d49f9ee482f1615a1294
cf-cache-status: DYNAMIC
report-to: {"group":"cf-nel","max_age":604800,"endpoints":[{"url":"https://a.nel.cloudflare.com/report/v4?s=NzckaMhU6aF%2BOBdua0zhehwY0E4Cdh0ZqxsJpqYU5oDLbOlgASqP7qgj0%2BJAKgYP60vKn%2FtvzHPWBelWruFJdhmUvBEQBLo3Lj%2FKq8Q%3D"}]}
cf-ray: 964e33970c48c174-BLR
HTTP/1.1 301 Moved Permanently
Date: Fri, 25 Jul 2025 19:53:06 GMT
Transfer-Encoding: chunked
Connection: keep-alive
Location: https://webpack.js.org/plugins/limit-chunk-count-plugin/
Vary: accept-encoding
Report-To: {"group":"cf-nel","max_age":604800,"endpoints":[{"url":"https://a.nel.cloudflare.com/report/v4?s=nOC7YV%2FGxAeCxfUNBQgtIv7U6iSMsbtxRVIgNaSOuY0bwwj5AX4cJJ8IeQtH%2FU9tK1A25BWfdBroNCZbxFucO288X9ZxyHL5n11MqZw%3D"}]}
Nel: {"report_to":"cf-nel","success_fraction":0.0,"max_age":604800}
Server: cloudflare
CF-RAY: 964e3398afdd6cd6-BLR
HTTP/2 200
date: Fri, 25 Jul 2025 19:53:06 GMT
content-type: text/html; charset=utf-8
content-length: 13471
nel: {"report_to":"cf-nel","success_fraction":0.0,"max_age":604800}
server: cloudflare
x-origin-cache: HIT
last-modified: Fri, 25 Jul 2025 11:09:39 GMT
access-control-allow-origin: *
etag: W/"688365f3-17367"
expires: Fri, 25 Jul 2025 20:03:06 GMT
cache-control: max-age=600
content-encoding: gzip
x-proxy-cache: MISS
x-github-request-id: A37E:32E213:88F6:A93D:6883E0A1
accept-ranges: bytes
age: 0
via: 1.1 varnish
x-served-by: cache-maa10241-MAA
x-cache: MISS
x-cache-hits: 0
x-timer: S1753473187.708903,VS0,VE233
vary: Accept-Encoding
x-fastly-request-id: 0f2f88e4551aa4fb17666c65f96346f5ee12c5ca
cf-cache-status: DYNAMIC
report-to: {"group":"cf-nel","max_age":604800,"endpoints":[{"url":"https://a.nel.cloudflare.com/report/v4?s=8AIZcWkSOrSxowTtW6kipjgEwoYxFLaZmY1ZbZwd40pfOBlj%2F4YHqdT%2FeBpl9NpIfvdfMKdbC2w00w1yMzAaOhSoV7ql6zLZcwjRxXU%3D"}]}
cf-ray: 964e3398bd0cc174-BLR
LimitChunkCountPlugin | webpack
Community
webpack
SplitChunksPlugin
- Defaults
- Configuration
- optimization.splitChunks
- splitChunks.automaticNameDelimiter
- splitChunks.chunks
- splitChunks.maxAsyncRequests
- splitChunks.maxInitialRequests
- splitChunks.defaultSizeTypes
- splitChunks.minChunks
- splitChunks.hidePathInfo
- splitChunks.minSize
- splitChunks.minSizeReduction
- splitChunks.enforceSizeThreshold
- splitChunks.minRemainingSize
- splitChunks.layer
- splitChunks.maxSize
- splitChunks.maxAsyncSize
- splitChunks.maxInitialSize
- splitChunks.name
- splitChunks.usedExports
- splitChunks.cacheGroups
- Examples
webpack contrib
MiniCssExtractPlugin
- Getting Started
- Options
- Examples
- Recommended
- Minimal example
- Named export for CSS Modules
- The publicPath option as function
- Advanced configuration example
- Hot Module Reloading (HMR)
- Minimizing For Production
- Using preloaded or inlined CSS
- Extracting all CSS in a single file
- Extracting CSS based on entry
- Filename Option as function
- Long Term Caching
- Remove Order Warnings
- Multiple Themes
- Media Query Plugin
- Hooks
- Contributing
- License
LimitChunkCountPlugin
While writing your code, you may have already added many code split points to load stuff on demand. After compiling you might notice that some chunks are too small - creating larger HTTP overhead. LimitChunkCountPlugin
can post-process your chunks by merging them.
new webpack.optimize.LimitChunkCountPlugin({
// Options...
});
Options
The following options are supported:
maxChunks
number
Limit the maximum number of chunks using a value greater than or equal to 1
. Using 1
will prevent any additional chunks from being added as the entry/main chunk is also included in the count.
webpack.config.js
const webpack = require('webpack');
module.exports = {
// ...
plugins: [
new webpack.optimize.LimitChunkCountPlugin({
maxChunks: 5,
}),
],
};
minChunkSize
Keeping chunk size above the specified limit is no longer a feature of this plugin. Use MinChunkSizePlugin instead.
Usage via CLI
This plugin and it's options can also be invoked via the CLI:
webpack --optimize-max-chunks 15
« Previous
Internal webpack pluginsNext »
MinChunkSizePlugin