-
Notifications
You must be signed in to change notification settings - Fork 304
component-size #520
Comments
It's useful in the sense it gives you a rough idea of relative sizes of packages that your using, if you're ocd about sizes of things. If I want to see the size of the compiled package I can just type A shortcut for doing this would be handy, but I imagine would have to make an opinionated choice wrt. minimization. For example we use closure compiler to get much better minimization than what uglify seems to produce. Just some thoughts... |
My only problem with closure compiler is that it's a pain in the ass to install I'm thinking of only showing the minimized sized of files. |
Yeah it's a pain, I made it slightly easier in the sense you can type I think the canonical uglify minifier would make sense for this command though, I would still find it useful as a rough estimate of minimized and gzipped sizes. |
it's super easy to delegate compression/minification outside component, not sure if it's really worth adding a command for when you can use |
but not on a per-component basis, both remote and local. plus, it's easy for you, but not most web developers (i didn't even know if this |
Could this not just be added as a feature to the existing component-size? |
yeah it could, but i'm thinking about how to improve its usefulness before refactoring it. |
So yeah it could just have a summary section and then individual component breakdown |
The biggest use case of this command for me is to check how many the bytes would be bring in with one component. Imagine one component takes of 1k of itself but brings in 5k other components, the other one component takes of 2k of itself but no other components, then the other one looks better on the size aspect. But if the 5k taken by other components was reused by other components within the app, the first one component looks better. If the component-size(or something else) command could show the total minified size of build.js file and minified js size of each component would be good enough for me. And I prefer uglifyjs as it's probably most widely used and easy enough to use and install. |
it could always be part of |
to view the total size of bundles unminified, minified, and minified + gzipped.
there's already https://github.com/ianstormtaylor/component-size, but it shows sizes on a per-file basis. not sure how useful that is since there's minification and gzip you don't take into account. maybe there's a better name for this command.
The text was updated successfully, but these errors were encountered: