Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

http2 AggressiveSplitting #88

Open
graingert opened this issue Mar 26, 2017 · 0 comments
Open

http2 AggressiveSplitting #88

graingert opened this issue Mar 26, 2017 · 0 comments

Comments

@graingert
Copy link

Similar to the webpack AggressiveSplittingPlugin https://medium.com/webpack/webpack-http-2-7083ec3f3ce6

Automatically split all the spritesheets into smaller sheets: This improves the caching while worsens the compression (and transferring for HTTP/1).

When the application is updated try hard to reuse the previously created sheets. Therefore every time the AggressiveSplittingPlugin finds a good chunk (size within the limits), it stores the sheets' images and hash into a records file.

Records is webpack’s concept of state that is kept between compilations. It’s stored to and read from a JSON file. postcss-sprites will have to recreate something likey this.

When the AggressiveSplittingPlugin is called again it first must restore the sprite sheet chunks from records before trying to split the remaining modules. This ensures that cached chunks are reused.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants