Created
November 6, 2013 14:57
-
-
Save juliangruber/7337388 to your computer and use it in GitHub Desktop.
browserify bundling tests
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# simple bundle | |
$ time browserify --debug lib/boot/index.js | wc -c | |
1397809 | |
real 0m1.726s | |
user 0m1.540s | |
sys 0m0.139s | |
# bundle without node_modules | |
$ time browserify --debug $(find node_modules/* -maxdepth 0 | sed -e 's/node_modules\//-x /g') lib/boot/index.js | wc -c | |
203418 | |
real 0m0.748s | |
user 0m0.688s | |
sys 0m0.098s | |
# bundle only node_modules | |
$ time browserify $(browserify --list lib/boot/index.js | grep node_modules | grep -v node_modules/browserify | perl -pe 's|.*?node_modules/([^/]*)/.+$|-r \1 node_modules/\1|g' | sort | uniq) | wc -c | |
480493 | |
real 0m2.477s | |
user 0m2.340s | |
sys 0m0.243s |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
That's excellent. Quick, npm it before it rots!