cost-of-modules icon indicating copy to clipboard operation
cost-of-modules copied to clipboard

Feature request: Add CI support

Open efimk-lu opened this issue 6 years ago • 3 comments

Part of a standard CI flow is to verify that a package size did not cross a certain threshold. Right now due to the way the results are outputted it's cumbersome to extract and assert the final package size value.

Suggested solution: Adding a new command line option, e.g. assert-smaller if the resulting package size is higher than the given number then fail with exit code different than 0.

efimk-lu avatar Oct 27 '18 18:10 efimk-lu

I think you're looking for this package https://github.com/siddharthkp/bundlesize

alshakero avatar Oct 29 '18 10:10 alshakero

But, it means I have to package it on my own, right ? I like cost-of-modules approach, just run and it works :-)

efimk-lu avatar Oct 29 '18 12:10 efimk-lu

Hey @efimk-lu, not sure if this is right tool

cost-of-modules does not look at your bundle size, it looks at the node_modules size

more here: https://github.com/siddharthkp/cost-of-modules#motivation

siddharthkp avatar Oct 30 '18 00:10 siddharthkp