A debate that pops up every so often in the office is whether minification is worth it when you have GZip available.
The short answer:
To find this out I looked at JQuery 1.8.1 from the Google Hosted Libraries. The results:
So — you can reduce your JS (or JQuery, at least) size by three simply by GZipping. If for some absurd reason you can't GZip then you'd best at least minify, but you get the best performance by using both.
*I'm not immediately sure what tool was used for minificationThe short answer:
- GZipping is always a good idea, and better than nothing.
- Minification is always a good idea, and better than nothing.
To find this out I looked at JQuery 1.8.1 from the Google Hosted Libraries. The results:
Technique | Size (kb) |
---|---|
Original | 256 |
GZip | 76 |
Minified* | 91 |
Minified + GZipped | 33 |
So — you can reduce your JS (or JQuery, at least) size by three simply by GZipping. If for some absurd reason you can't GZip then you'd best at least minify, but you get the best performance by using both.
No comments:
Post a Comment