3 ms·
It looks like Webpack 2 will have support for tree-shaking: https://github.com/webpack/webpack/pull/861#issuecomment-149997270 https://github.com/webpack/webpac
by dceddia 11y ago
It looks like Webpack 2 will have support for tree-shaking:
https://github.com/webpack/webpack/pull/861#issuecomment-149997270 https://github.com/webpack/webpack/pull/861#issuecomment-149...
There's also rollup.js (another module bundler) that supports tree-shaking: http://rollupjs.org/ http://rollupjs.org/
Either way, it seems like the code needs to be using ES6 modules to make it all work.
- EvanPlaice 11y agoJSPM already uses it for sfx builds https://github.com/systemjs/builder/pull/205 https://github.com/systemjs/builder/pull/205 ES6 modules allow devs to easily specify and import only the parts of a library that are being used. The bundler takes care of pulling in the necessary parts. No magic required.