Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build size info #847

Closed
tbillington opened this issue Oct 4, 2016 · 5 comments
Closed

Build size info #847

tbillington opened this issue Oct 4, 2016 · 5 comments

Comments

@tbillington
Copy link

Would it be useful to try and give a breakdown of the build size when you build? Sometimes I include a few libraries and the bundle size balloons out and I'm not too sure why, and with create-react-app wrapping webpack it's a bit cumbersome to run these tools eg webpack-bundle-size-analyzer.

Is it worth looking into some way of displaying this when npm run build is used, similar to how gzip size is shown now?

@tbillington
Copy link
Author

Seems source-map-explorer is a more accurate way of seeing built module size.

The data looks like this (from the visual tool).
source-map-explorer

@tbillington
Copy link
Author

tbillington commented Oct 5, 2016

Example build output

File sizes after gzip:

  134.87 KB  build/static/js/main.195ff791.js
  1.4 KB     build/static/css/main.3a26db49.css

Dependencies

  35% (50 KB)  immutable-js
  32% (30 KB)  moment-js
  21% (25 KB)  react-js
  ...

@themre
Copy link
Contributor

themre commented Oct 5, 2016

I had also some similar proposal, see here #798.

@tbillington
Copy link
Author

Ah, missed that. Seems analysing the js map wasn't mentioned though, it seems like a more accurate way of determining the sizes over the pre-webpack build sizes.

@gaearon
Copy link
Contributor

gaearon commented Oct 5, 2016

@tbillington This sounds reasonable! I’ll close in favor of #798 but you are welcome to submit a pull request implementing what you suggested.

@gaearon gaearon closed this as completed Oct 5, 2016
@lock lock bot locked and limited conversation to collaborators Jan 22, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants