Comparison
ChunkvsVendor chunk
Chunk
the build wrote out eleven numbered JavaScript files and the page only requests three of them.
One output file produced by the bundler, containing a subset of the module graph. Chunk boundaries decide what is downloaded when and what can be cached independently, so how the graph is cut matters more than how much of it there is. Too few chunks and every change invalidates everything; too many and you pay per-request overhead and lose compression efficiency.
Full entry →Vendor chunk
you split the dependencies into their own file so a change to your code does not invalidate them.
A chunk holding third-party dependencies, separated because they change far less often than application code. It exists purely to serve the cache: returning visitors re-download only what changed. One large vendor chunk is a blunt version of this, since a single dependency bump invalidates the lot; splitting the largest dependencies out individually is the refinement.
Full entry →