views:

215

answers:

6

There are a lot of JavaScript libraries out there these days (extJs, Scriptaculous, Dojo, prototype, Solvent and many more). Couldn't find any site comparing cons and pros.

Could anyone give recommendations? Things to consider: - size - performance - Cross-Platform - ease of use and documentation - (special reason to use a specific one when developing in python/Django?)

Thanks! Yaniv

+1  A: 

Don't forget jQuery
And I think it's more like cross browser than cross platform.

daniels
+6  A: 

jQuery is very good, and probably the most common.

Zifre
+1  A: 

In my opinion, the most important thing to consider when choosing a framework is coding style. Every framework does roughly the same thing, but in different ways.

My advice is to choose the one that makes most sense to you. The size, performance and browser compatibility is about the same in every framework.

You may also want to take a look at "Comparison of JavaScript frameworks" at Wikipedia for some technical details about each framework.

moff
+1  A: 

I'll have to agree with the above (i.e. jQuery) - but also recommend Prototype

Prototype is a clean, simple, lightweight javascript engine that is server side language agnostic.

Chaos
I think of jQuery as an extension of the DOM, and prototype as an extension of Javascript.
Tracker1
+2  A: 

jQuery is the most popular right now, and for good reason!

  • It is very lightweight. The mimified version is only 19kb.

  • You can use the jQuery hosted by google for increased speed, (using this there is a chance that your user already has it cached).

  • It (almost always) works the same in all browsers, stopping the need for a lot of the previously hated cross-browser development testing.

  • It is based on CSS which is familiar with web designers.

  • It uses CSS3 componenets.

  • It has a HUGE number of plugins available from the community. It is also easy to write your own.

  • It is used by some massive web companies. StackOverflow, digg, Dell, Google etc.

Jon Winstanley
+1  A: 

My answer to a very similar question:

Jquery

  • Fast
  • Well documented
  • Easy to use
  • Chaining
  • Unlike prototype it doesn't extend an object if you didn't specifically ask for it (try looping an array in prototype)
  • easy-to-use AJAX (I love the $.ajaxSetup() function)
  • Nice Event handlers
  • CSS selectors
  • filtering your selection
  • did I mention chaining?
  • Small (only 30kb)
  • Nice little build-in effects.
  • Plugins

(http://stackoverflow.com/questions/394601/which-javascript-framework-jquery-vs-dojo-vs/394837#394837)

Pim Jager
myarray.each(function(item){.. use item...}); that's the easiest... Data structures are nicer through prototype, but loving DOM interaction w/ jquery.
Tracker1