jQuery is a fast and concise JavaScript Library that simplifies HTML document traversing, event handling, animating, and Ajax interactions for rapid web development. -- From the Jquery Website.
Jquery is one of the many Javascript frameworks out there. Its competition includes YUI, Prototype, Moo etc.
In additions to the framework; Jquery also has a powerful UI framework. Jquery and Moo have the most complete and easy to use UI framework now. It has widgets such as sliders, tabs, accordions, calendars, dialog and modal windows. It also has a very nice button framework.
You can find more information on their website http://ui.jquery.com.
When Prototype started off there was alot of hype around it. Afterall it was the first Javascript framework in the market. To top it off it was piggy-backed on Ruby on Rails which was hotter than Jessica Alba.
I think Jquery has a very vibrant community of developers and contributors compare to Prototype now. There is also a vast amount of documentation and code available to Jquery developers. Prototype also lacks a deep and complete UI framework. LivePipes is the most complete UI library Prototype has now.
Technically I love both the frameworks. I started using Prototype in the early days, and moved to Jquery later.
The jRails project is a drop in replacement for Prototype/ script.aculo.us on Ruby on Rails. jRails provides the compete set of helpers.
By using the jRails project you can harness the vast amount of libraries that JQuery already has.
You can install jRails directly from github.
script/plugin install git://github.com/aaronchi/jrails.git
This should download and install the plugin in your vendor/plugins/ directory.
The following will install the Jquery and JqueryUI libraries in the public/javascripts folder and remove the Prototype and script.aculo.us files.
rake jrails:js:install rake jrails:js:scrub
javascript_include_tag :defaults will now use Jquery instead of Prototype. If you use the default Ruby on Rails helpers for Javascript I doubt you will have to change anything. You may only face bump if you hard code your Javascript. Finding replacements for other Prototype libraries is easy.
All the Ruby on Rails applications I have migrated from Prototype to Jquery have been very smooth. I would suggest if you have some spare time on your hands its worth giving a jRails a shot.
Comments
Post new comment