Google and Yahoo JavaScript CDN

One way to speed up loading of a website is to use Content Distribution Networks (CDN) for resources that don’t update often, such as JavaScript, images, and CSS. A good CDNs for a large site can run into the thousands of dollars, fortunately for those that rely on JavaScript frameworks such as jQuery, Prototype, and YUI you can use the use Google’s and Yahoo’s broadband.

Google hosts a large number of JavaScript libraries, including jQuery, jQuery UI, Prototype, Dojo, and even YUI! Using the JavaScript libraries hosted on Google should make your page load faster. Google give you an absolute URL address for each version of the JavaScript library you are trying to use, this makes it easy to load the required scripts.

http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js

Yahoo also provides free hosting of the Yahoo! User Interface from their servers.

One theory why using Google hosting for jQuery and similar hosted JavaScript frameworks is that if many of the sites you visit use them, your browser will already have a fresh cached version ready for you. My question is, why don’t browsers come pre-installed with the commonly used versions of JavaScript libraries? Odiously, if this feature would be enabled from the top tier browsers there would also need to implement a discovery mechanism to download into a browser repository new versions of those JavaScript libraries. A code discovery, management, and repository system that I have seen work well is that provided by Maven. In Maven, you can indicate a number of online and local code repositories from which to download required dependencies.

Enjoy. Share. Be Happy.
  • Twitter
  • Facebook
  • StumbleUpon
  • del.icio.us
  • Tumblr
  • Google Bookmarks
  • FriendFeed
  • Yahoo! Buzz
  • Reddit
  • Digg
  • HackerNews
  • Suggest to Techmeme via Twitter
  • LinkedIn
  • Ping.fm
  • Identi.ca
  • Mixx
  • Furl

Related posts:

  1. Top JavaScript and Web Performance Presentations on Google Tech Talks
  2. Dynamically Create HTML Elements with JavaScript
  3. Learning JavaScript
  4. Chain JavaScript Events
  5. Connect with Folks in Google, Sun, Yahoo, and Microsoft via Twitter

This entry was posted in JavaScript, TechKnow, Tools. Bookmark the permalink. Post a comment or leave a trackback: Trackback URL.

One Comment

  1. Posted August 27, 2010 at 12:53 am | Permalink

    great blog… “Why dont Browser come with pre- installed scripts ?”.. awesome thinking.. will post in browser discussions..

Post a Comment

Your email is never published nor shared. Required fields are marked *

*
*