Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Disadvantages of switching from jQuery to Dojo

I am considering using Dojo in some new projects (or at least including it),, Partially because of it's compatibility with Google Closure Compiler's Advanced mode which will (hopefully) entirely delete all unused code.

What would I lose? (besides familiarity with syntax)

(also, generally any tips on what is different would probably be helpful)

like image 247
700 Software Avatar asked Mar 14 '11 19:03

700 Software


1 Answers

I use jQuery myself, but to sum it up jQuery appears to be better documented and easier to do cool stuff "out of the box". Dojo appears to be easier to extend if you know what you are doing. I got this info from the community wiki here:

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 30 KB)
  • Nice little build-in effects.
  • Plugins

Dojo

"Being a Dojo developer I would recommend Dojo. While my choice is not surprising, I became a Dojo developer because I found following things, which are done better than in other JavaScript frameworks:"

  • OOP (and other paradigms) done right.
  • Widget infrastructure done right.
  • Modules done right with all necessary goodies:
    • Lazy loading of modules dynamically.
    • Possibility to extract only necessary modules and build a custom one-file profile.
    • Asynchronous loading of modules if desired.
    • Simple integration with CDNs for heavy-duty web applications.
  • Sheer breadth of available modules in DojoX including graphics, charting, grids, and so on.
  • Ability to use it in non-browser environments.
  • Attention to details in widgets:
    • support for i18n (including LTR and RTL languages),
    • support for l10n (including standard date, currency, number formatting),
    • provisions for people with special needs (automatic high-contrast mode, keyboard-only support, and so on) — useful for regular users too, and mandatory for most government contracts.
  • Smart people in the community (last but not least) — as much as I love hand-holding for novices at some point every developer becomes "seasoned" and needs much more than that.

"Smart people in the community (last but not least) — as much as I love hand-holding for novices at some point every developer becomes "seasoned" and needs much more than that. If all you want is to write one-liners and add simple progressive enhancements to existing web applications, you can do it with pretty much any framework, or even with a pure JavaScript. But as soon as your web application becomes bigger or more complex good packaging, good support for your favorite methodologies, good building blocks, and the ability to make your own building blocks become more and more important. That's why I settled on Dojo, and never looked back."

like image 68
themerlinproject Avatar answered Sep 21 '22 17:09

themerlinproject