stealjs / steal-tools

Build easy. Load fast.
https://stealjs.com/docs/steal-tools.html
MIT License
67 stars 23 forks source link

Implement tree shaking #984

Closed matthewp closed 6 years ago

matthewp commented 6 years ago

This pull request implements tree shaking. It uses rollup under the hood for the heavy lifting so we don't have to worry about maintaining complex dead-code elimination logic. This will be released as a prerelease first to ensure existing applications are not negatively effected.

It is easily turned off with the --no-tree-shaking cli flag of treeShaking: false from the JavaScript API.

matthewp commented 6 years ago

Closes #974

coveralls commented 6 years ago

Coverage Status

Coverage increased (+0.3%) to 93.303% when pulling 41552ede4d606679e844b4f6d1e4144949cba288 on treeshake-rl into d69afa3fd91b28788730d9028f8c0c762e9283bd on master.

coveralls commented 6 years ago

Coverage Status

Coverage increased (+0.3%) to 93.303% when pulling 41552ede4d606679e844b4f6d1e4144949cba288 on treeshake-rl into d69afa3fd91b28788730d9028f8c0c762e9283bd on master.