stealjs / steal

Gets JavaScript
https://stealjs.com
MIT License
1.37k stars 521 forks source link

Maintain all tree-shaking state during the build #1474

Closed matthewp closed 6 years ago

matthewp commented 6 years ago

This fixes an issue with tree-shaking and the build where state from a previous bundle would not always be carried forward into new bundles. This happened when a previous bundle didn't have all of the same dependencies.

This change maintains a "treeShakeConfig" object that always carries forward from bundle to bundle.