antonmedv / jsize

Find out minified and gzipped npm package size
MIT License
178 stars 12 forks source link

Add support for total sizes #20

Closed DylanPiercey closed 7 years ago

DylanPiercey commented 7 years ago

This adds support for https://github.com/antonmedv/jsize/issues/17.

Also this PR is much larger than I initially thought it would be because I realized that I couldn't just add up all of the sizes but instead have to pass all of the entries to webpack.

This is because if we added up all of the sizes it would not account for packages that have a shared runtime. Eg: lodash/map+lodash/filter actually has like 5kb shared.

@antonmedv would love your feedback if any.

antonmedv commented 7 years ago

Nice work!