3 ms·
jQuery is not that large and very likely to be cached an a users machine. So, it's IMO disingenuous to harp on it. If your playing with larger and less 'standa
by Retric 11y ago
jQuery is not that large and very likely to be cached an a users machine. So, it's IMO disingenuous to harp on it.
If your playing with larger and less 'standard' library's then that's a different story.
- Conlectus 11y agoThere are approximately 5 million different CDNs hosting different versions of jQuery. Cache hits are actually quite low.
- Retric 11y agoSource? And even then it's ~83KB vs the average page of ~2250K.
- tedmiston 11y agoThree popular ones is not "approximately 5 million": Google, cdnjs, MaxCDN.
- notahacker 11y agoeven the sites using one of these 3 CDNs probably specify aa specific minor version of jQuery from this list http://code.jquery.com/jquery/ http://code.jquery.com/jquery/ (OK, so I doubt many sites are specifying the beta or uncompressed versions, but there's still a pretty good chance that somebody hasn't downloaded the relevant version from the relevant CDN recently enough for it to be in their cache, especially if they're browsing on their phone)
- Grishnakh 11y agoI have a small website that uses jQuery, but I by default point to the Google-hosted version (with a fallback to my own site if that fails), but I also use an older version that's a little over half the size of the current version. What I'd like to see, however, is a way of trimming down jQuery to only include the functions I actually use. I only use two functions out of the whole library IIRC, so I really don't need to load the whole thing. Maybe one day when I have some spare time and other projects out of the way I'll try stripping those functions out of jQuery and just hosting them locally.