Skip to content

joshduck/webpack-dynamic-import

master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
src
 
 
 
 
 
 
 
 
 
 
 
 

React Bundle Preloading

This project makes it possible to determine which Webpack bundles should be preloaded in the client.

We do this by recording which modules were dynamically imported during server render and using a pre-generated manifest to find the corresponding client bundles. This is still a work in progress

Why is this important?

Dynamic imports allow us to split our application up into smaller chunks so that we spend less time loading and preparing JavaScript in the browser. But because bundles are loaded only when used, we may end up waiting for several round trips as we load JavaScript, execute some code, and then discover a new dynamic import that requires even more JavaScript to be loaded.

Before and after

Before After

How this works

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published