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

Add flag to re-enable deep dynamic chunk optimization #4837

Merged
merged 4 commits into from Feb 5, 2023

Conversation

lukastaegert
Copy link
Member

This PR contains:

  • bugfix
  • feature
  • refactor
  • documentation
  • other

Are tests included?

  • yes (bugfixes and features will not be merged without tests)
  • no (this feature is marked as "experimental" and I hope to make it obsolete again soon. Should it turn out that we need to persist the feature, I will add an additional test)

Breaking Changes?

  • yes (breaking changes will not be merged unless absolutely necessary)
  • no

List any relevant issue numbers:

Description

This adds a flag output.experimentalDeepDynamicChunkOptimization. When set to true, it will allow the full dynamic import tracing algorithm to run to potentially create fewer chunks at the cost of performance.
I hope to remove this feature again in a future release if I manage to make the full algorithm fast enough.

@netlify
Copy link

netlify bot commented Feb 4, 2023

Deploy Preview for rollupjs ready!

Name Link
🔨 Latest commit 1f3d7d8
🔍 Latest deploy log https://app.netlify.com/sites/rollupjs/deploys/63df36fd55eb3000097ac87c
😎 Deploy Preview https://deploy-preview-4837--rollupjs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@github-actions
Copy link

github-actions bot commented Feb 4, 2023

Thank you for your contribution! ❤️

You can try out this pull request locally by installing Rollup via

npm install rollup/rollup#deep-dynamic-chunk-optimization

or load it into the REPL:
https://deploy-preview-4837--rollupjs.netlify.app/repl/?pr=4837

@codecov
Copy link

codecov bot commented Feb 4, 2023

Codecov Report

Merging #4837 (1f3d7d8) into master (5368e80) will increase coverage by 0.00%.
The diff coverage is 100.00%.

@@           Coverage Diff           @@
##           master    #4837   +/-   ##
=======================================
  Coverage   98.99%   98.99%           
=======================================
  Files         219      219           
  Lines        7877     7883    +6     
  Branches     2181     2184    +3     
=======================================
+ Hits         7798     7804    +6     
  Misses         26       26           
  Partials       53       53           
Impacted Files Coverage Δ
src/utils/options/mergeOptions.ts 100.00% <ø> (ø)
src/Bundle.ts 100.00% <100.00%> (ø)
src/ast/variables/LocalVariable.ts 96.10% <100.00%> (+0.15%) ⬆️
src/utils/chunkAssignment.ts 100.00% <100.00%> (ø)
src/utils/options/normalizeOutputOptions.ts 100.00% <100.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@lukastaegert lukastaegert changed the title At flag to re-enable deep dynamic chunk optimization Add flag to re-enable deep dynamic chunk optimization Feb 4, 2023
@lukastaegert lukastaegert merged commit 53cf9fe into master Feb 5, 2023
@lukastaegert lukastaegert deleted the deep-dynamic-chunk-optimization branch February 5, 2023 05:11
@rollup-bot
Copy link
Collaborator

This PR has been released as part of rollup@3.14.0. You can test it via npm install rollup.

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

Successfully merging this pull request may close these issues.

rollup3.7.2 chunking algorithm introduce tow many js chunks vite4 generate double count js chunks than vite3
3 participants