Skip to content

Instantly share code, notes, and snippets.

@alekseykulikov
Last active October 24, 2015 15:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save alekseykulikov/3c76e1589de18ad08da4 to your computer and use it in GitHub Desktop.
Save alekseykulikov/3c76e1589de18ad08da4 to your computer and use it in GitHub Desktop.
Estimate production size of npm front-end package
$ npm i -g browserify uglify-js pretty-bytes
$ npm i react
$ browserify node_modules/react | uglifyjs -m | gzip | wc -c | pretty-bytes
> 51.58 kB
$ npm i backbone jquery
$ browserify node_modules/backbone | uglifyjs -m | gzip | wc -c | pretty-bytes
> 41.99 kB
$ npm i socket.io-client
$ browserify node_modules/socket.io-client | uglifyjs -m | gzip | wc -c | pretty-bytes
> 20.64 kB
$ npm i treo
$ browserify node_modules/treo | uglifyjs -m | gzip | wc -c | pretty-bytes
> 2.8 kB
$
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment