Share

From this page you can share Making Prototype Smaller to a social bookmarking site or email a link to the page.
Social WebE-mail
Enter multiple addresses on separate lines or separate them with commas.
Making Prototype Smaller
(Your Name) has forwarded a page to you from Ajaxonomy
(Your Name) thought you would like to see this page from the Ajaxonomy web site.

Making Prototype Smaller

Tagged:  

Prototype is one of the most used JavaScript libraries and is used for many other libraries. The problem with Prototype is that it is a rather large library. This has forced many people to either shy away from the library or to try and modify it. I say that just for the $ (for those of you who haven't use prototype the $ is used like document.getElementById) functionality the library is worth using.

I ran Prototype through ShrinkSafe and was able to get the code quite a bit smaller. The Prototype.js (I'm using version 1.6) file went from 122K down to 82K. That is an amazing 40K less which helps in using the library.

Below is a demo using the compressed and uncompressed versions of Prototype (the demo uses Script.aculo.us 1.8 and is taken from the demos that come with that library)
Click here to see the uncompressed version
Click here to see the compressed version

You can download the compressed version of Prototype here.

Now that you have a smaller version of Prototype use it to improve the load time of your application.

prototype.png