Let Google host your javascript libraries

Posted By Venu Thomas

GoogleCode

An interesting possibility offered by Google developers use it as a CDN (content distribution network) for open source javascript libraries popular. In practice, this means is that in your web development, instead of going to your server for libraries that use scripting, you can directly reference and use the possibilities offered by this company in its servers.

This provides several advantages are not insignificant:

  • First, the discharge of these libraries will, for the client, probably faster than if you have to get from your server through the Internet. This is Google’s network infrastructure, and that means guarantees.
  • Second, and related to the above, if this is a high traffic website, the audience will surely be allowed infinitely greater than you can offer to another server.
  • Third, if the user has previously visited another site that also use the same library, will benefit from the local cache of the same, because your browser does not again discharged. And in any case, they would be taking advantage of Google’s cache optimizations.
  • fourth, do not consume bandwidth from your provider, although this is negligible. And I mean negligible bandwidth, not the provider ;-)
  • fifth, you can use the libraries from sites hosted somewhere where you could not, or is not easy, upload scripts, as the platform Blogger from which to write.

At this point includes: development frameworks, in all versions available:

  • jQuery
  • jQuery UI
  • Prototype
  • script_aculo_us
  • MooTools
  • Dojo
  • SWFObject
  • Yahoo! User Interface Library (YUI)

If you’re already using Google Ajax libraries (such as the Visualization API, or Google Maps), and get through the charger google.load (), you can also use it to download these frameworks. You can also do so through a direct reference, such as:

?View Code JAVASCRIPT
<script 
src="http://ajax.googleapis.com/ajax/libs/prototype/1.6.0.2/prototype.js">
</script>

Oh, and not worry about changing versions, or anything. Google is committed to live indefinitely all distributions to be published and include updates as they appear.

Finally, and to provide a negative view, some people think that this is one more strategy for Google to get information about users’ browsing, code execution from its servers enable cookies and reading of data that could be used for purposes other than those provided on your website. Still others think it could be a source for the spread of malicious code if someone managed to hack these archives. Obviously not a good idea to use this option if you go to work in local mode, offline.

For more information on how to download and libraries available, you can visit the Developer Guide for Ajax libraries API.

Tags: , , ,

  •  
  • Share with others:

    Thanks for visiting us! If you enjoyed these icons please feel free to share them! Or if you want to know what's going on with WiseCodes.com, follow us!

    3 Responses to “Let Google host your javascript libraries”

    1. [...] few days ago said the possibility of using the infrastructure of Google to host JavaScript libraries for our applications. Well, now that Microsoft has launched a similar service, Microsoft Ajax CDN , [...]

    2. More javascript on the web: Microsoft Ajax CDN « WiseCodes : Bringing You The Power of Code !! your flag on September 17th, 2009 at 8:40 PM
    3. I don’t usually post but I enjoyed your blog a lot, thanks alot for the great read.

    4. Download Movies your flag on April 12th, 2010 at 4:44 AM
    5. Thanks a bunch! That was really informational, I just saved your website.

    6. Custom Motorcycles your flag on April 17th, 2010 at 3:57 AM

    Leave a Reply

    Anti-Spam Protection by WP-SpamFree

    Locations of visitors to this page eXTReMe Tracker