Is jQuery Better than Dojo

  • jquery-vs-dojo

Note on Oct 3, 2014: I am Aykut, founder of Worth Of Web Academy. This article was written by a guest writer who is not writing at this blog now. This topic is not my area of expertise but after I checked comments below, I decided to put this note here. This article can include inaccurate statements. I encourage to read the article and comments to get involved in the discussion. I did not want to delete it completely because I want future readers to reach everything on this page. Thanks for your consideration 🙂

JQuery is a JavaScript library whereas Dojo is a JavaScript toolkit. Both are Open Source software.  JQuery provides the easy interaction between HTML and JavaScript through JavaScript Library. It is used for handling events, creating animations, reading and manipulating HTML document and creating Ajax application with Ajax ASP.net and PHP. On the other hand, Dojo is used for creating dynamic web user interfaces by providing widgets, high level Input and Output abstraction and utilities. JQuery is licensed by MIT and it was started at Rochester Institute of Technology in January 2006 by John Resig. Dojo is licensed by BSD or AFL and it was released in 2004 by Dylan Schiemann, David Schontzler and Alex Russell. JQuery allows the customization of plug-ins library on top of inbuilt JavaScript libraries. On the contrary, Dojo enables rapid development across platforms between JavaScript, Ajax and web applications.

For the comparison of jQuery vs Dojo

  • JQuery provides User Interface libraries with many useful functionalities. JQuery is easy to use and customization feature is making it popular and adoption is all time high. Alternatively, Dojo toolkit provides the features of widget toolkit. It also comes with the feature of 2D vector drawing, 3D, drag and drop support of tree widgets. User interfaces that are dynamic in nature are created by using this toolkit.
  • One of Jquery’s killer features is its compatibility with many web languages like PHP, ASP, CGI, Servlet etc. Dojo is JavaScript and HTML based toolkit. Dojo has achieved 40,000 downloads around the world.
  • As far as usage of Jquery vs Dojo is concerned, Dojo is a rapid development toolkit for web oriented software on desktop and mobile and internet applications without using the browser’s inbuilt graphics technology. Dojo is being used by all the popular internet browsers like Internet Explorer, Google Chrome, Safari, Firefox, Opera and on smart phones and tablets by Apple (iPhone, iPad) Google ( Android) and BlackBerry. Generally, JQuery is used mostly for the web application and dynamic web pages. JQuery is being used by Wikipedia, WordPress, BackBone etc. The JQuery can be downloaded from http://jquery.com/ whereas Dojo Toolkit can be downloaded from http://dojotoolkit.org/

For the DOM (document object module) features on Jquery vs Dojo, JQuery provides the selection of one or multiple element and group of Document Object Model DOM elements. And can customize the properties of DOM element like hide, show, add, subtract, find DOM element and many more. On the other hand, Dojo provides the functionality of connection between DOM element and function of Dojo easily. Dojo contains many DOM elements, HTML, SVG and Style packages with handling and manipulation power between DOM and SVG.

So when it comes to JQuery vs Dojo, we may conclude that, JQuery is better than Dojo because:

  • Dojo provides many customizing options but it is a bulky and heavy toolkit whereas JQuery is a light weight with 19K compressed base libraries.
  • Dojo requires a higher network bandwidth than JQuery.
  • At present, the Dojo toolkit is not well documented and the tutorials are less, making it difficult to get in-depth help with development. For JQuery, as many documents and tutorials are easily available out there, it will be the best option to get started.
Thanks for reading!
  • Share: If you know someone who might find this helpful, please share it.
  • Related Posts: Check recommended posts from our blog below.

About the Author:

13 Comments

  1. Daniel_Automitive March 1, 2013 at 8:55 am

    Thanks for a good article – you are right in your conclusions. I have developed LOB web apps (not web pages) with both – but my vote goes with dojo because of AMD – allows me to build big complex modula systems – plus the graphing and data grids work well. With ASPMVC my vote is for jQuery because of the VS integration

    • Saidur Rahman Rhedoy March 2, 2013 at 5:47 am

      “because of AMD – allows me to build big complex modula systems”
      Well, Daniel, presently we are mainly focusing on guiding newbies in the proper direction and thus helping them get started easily when it comes to web development and programming. That’s why the writer here actually advises the young learners that it will be a good choice if they go for JQuery first. Hope this makes sense. 🙂 But we will gradually cover many complex and advanced topics as well. So please keep in touch and thanks for commenting!

  2. Arjun Pandav May 1, 2013 at 9:22 pm

    “One of Jquery’s killer features is its compatibility with many web languages like PHP, ASP, CGI, Servlet etc”

    This IMHO is an inaccurate at best and irrelevant statement to make. One is server side, other is client side. One can argue that separation of concerns (view vs middletier) is best achieved when you have a solid widgeting and UI toolkit which keeps a nice looking UI layer decoupled from from what ASP.Net and JSPs do best (i.e. server side processing)

    • Saidur Rahman Rhedoy May 2, 2013 at 9:02 am

      Thanks Arjun for your opinion. I think when it comes to which one is better between jQuery and Dojo, the debate can go on and on. But at the end of the day, we must say jQuery library is currently dominating the server side events. And what we are trying to do here is give an insight about the popular trends to the newbies who often face difficulties on deciding what should they go for at the beginning level. So we always encourage our writers to write articles keeping this guideline in mind. Hope you will get my point.

      • Ivaylo Slavov June 26, 2014 at 5:09 pm

        Without specifying the exact relationship between jQuery and these serverside technologies (how do they really work together), this is misleading.jQuery has nothing in it that is explicitly done to work better with PHP, ASP (and why for God’s sake you’ve put CGI?) or any other server-side technology, as is the same for Dojo. A newbie, not having enough experience with both, and not experienced much with the server-side technologies coud get mislead by this, I support the stance of jquery being indeed easier and more-suitable for learners, but please, do not list server side technologies here as advantages to jquery.

      • Mvied July 8, 2014 at 12:03 pm

        This article is full of incorrect information and assumptions. You have no idea what you’re talking about. You need to actually do your research before you write an article on the subject. You’re giving horrible advice to novice developers. This is not a matter of opinion. The two projects have entirely different goals and architectures and while they share some functionality, they do not serve the same purpose AT ALL. To think that you can come up with a list of generic reasons why you should use jQuery or Dojo on every project is absurd. You need to evaluate the needs of the project and use whatever tool fits the job. The features provided by jQuery are a very small part of what Dojo does. Very very small. Dojo is the largest, most-tested UI toolkit on the web. Any JavaScript developer worth their salt should be familiar with Dojo. You might learn a thing of two.

      • Manachi May 29, 2016 at 11:32 pm

        “at the end of the day, we must say jQuery library is currently dominating the server side events.”

        What does that even mean? lol

    • mike July 25, 2014 at 4:05 pm

      My mind exploded when I read that line. I would be curious as to what steps the author’s mind took to reach that assumption. But it was quite amusing to say the least. I wonder if his main issue is that he’s writing javascript inline with in his HTML and doesn’t understand dojo’s AMD architecture. As such just assumed dojo isn’t compatible with php because he couldn’t get modules to work. LoL amusing to say the least.

      Hopefully beginning developers won’t head this guy’s advice. But even if they do, it just means better pay and job security for those of us who don’t.

    • Aykut Pehlivanoglu October 3, 2014 at 9:22 am

      Guys, sorry for the trouble this post created. I read this post and your comments now (I know a little bit late 🙂 ). A guest writer wrote this and our editor approved back then. After I read your comments, I decided to put a note to the start of post. Hope your comments will help future readers 🙂

  3. muetschard July 11, 2013 at 7:04 pm

    If you need some make-up to brighten up a bland HTML Web page, resorting
    to (quite script/function oriented) jQuery is the ‘right’ thing (I
    say this in favor of jQuery even though dojo/dijit can do that too to
    some degree).

    When you need or want to write a a client-side app with highly dynamic,
    (meta) data driven UI layout and UI logic – or even a Web 2.0
    application in Single Page Architecture (SPA) where except the
    backend services everything is written in JavaScript – you are better
    off with a framework / toolkit that implements all the concepts and
    components you find in large, grown-up, and successful software
    systems / applications.

    Your bias shows blatantly…’ I hear you say… and – yes – you are right:
    it all depends what has to be done.

    Great bang for the buck you get with jQuery. jQuery’s brilliant features
    transforms frugal (groups of) Web page elements into function rich
    ones that deliver a very pleasant user experience. But beyond using
    what jQuery gives you out of the box and its compounds, jQuery
    becomes very challenging. When you find in jQuery’s box what you
    need, there is no need to look out for greener gras… (Why fix it,
    when it’s not broken!). And even if you cannot find it in the box,
    rarely you will break out (right away): You stay within and use your
    gained experience to build a ‘nice’ kludge tower. Only when the
    tower’s operation / maintenance becomes unmanageable you wonder if
    there is something out there with a potential for growth beyond the
    current limitations.

    With
    dojo, it is (quite) a bit different. To get dojo – or dijit (the
    visual part, widgets) – off the ground and (visually) flying as
    brilliantly as jQuery – you need quite a bit more bucks: more bucks
    not just in terms of time, but also in terms of CS savviness of your
    builders.

    DTP and CS are two skill domains – and both are needed to succeed in
    today’s www era. Both started approaching www from their base with
    the tools they had at hand, served them well, and (could) understand.
    Therefore it depends not only on what you want to achieve, but also
    resources you have to get there. Therefore, in the past, it was
    either this or that framework.

    Luckily, with recent development in the area of javascript frameworks and how these frameworks are implemented (in the namespace less javascript
    context), frameworks can be combined. Founders of once mutually
    exclusive – no coexistence – and absolutely incompatible javascript
    frameworks joined, for example, the common javascript module loader
    bandwagon to enable implementers to pick and chose and combine
    components from any framework and have not to become religious. This
    opening-up and growing together in the lower-level, technical layer
    of the once disjunct frameworks turns out beneficial for all and
    foremost for the user. The user gets the best of all what is out
    there, and management likes the potential for total cost of ownership
    (TCO) going down.

    Total rewrites in a different world with the expensive (re)start from
    scratch are not required anymore to move beyond the limitation of the
    initially chosen framework(s).. It is rather a ‘smooth’/gradual and
    ongoing replacement of not so suitable components of one framework
    with more suitable ones from another ones. For reaching the state of
    ideal coexistence – and actual TCO decline – still a lot of ground
    has to be covered… not just by the framework builders, but also by
    the ‘users’ – developers, just like me – to let go outdated
    experience biased from my origins and that have now became prejudice.
    I have to open up as well and acknowledge that all frameworks have
    mended (most of) their weaker areas. Also, I don’t need anymore to
    hide my envy for the cool (visual) jQuery features behind a
    discussion of ‘this is better than that’ by pointing out (just) the
    other framework’s (may be) not so strong areas. Now, I can enjoy all
    (of both) worlds, move on, and focus on solving the actual problem…
    a win-win situation for all involved parties – most notable so for
    the end-user.

  4. Greg July 30, 2013 at 4:43 pm

    If you are a newbie… you must realize jQuery and Dojo are both equally good at manipulating DOM objects. If you need widgets, choose dojo. If you don’t, choose jQuery. And, as far as the conclusions arrived by the author, dojo is not bloated… it’s bigger by 15k (you can build a <30k dojo runtime). I work on a very large eCommerce site using dojo and the response time/bandwidth usage and very very good. The author's conclusions don't portray the pros/cons of jQuery and dojo fairly nor realistically and Mr. Saidur comments are disproportionately biased.

    • steve November 9, 2015 at 11:51 pm

      A minimum of 100k runtime will give you the equivalent of jquery dom selector engine. 30k build merely gives you require and some of dojo core. Not to mention the flaw that dojos version of require masks errors. Also dojo is not equal to jquery at manipulating the dom.

  5. steve January 13, 2014 at 8:45 am

    the first thing I have read is

    JQuery is a JavaScript library whereas Dojo is a JavaScript toolkit.
    Jquery is easy bla bla bla…
    On the other hand, Dojo is used for creating dynamic web user interfaces by providing widgets, high level Input and Output abstraction and utilities.

    Define library and toolkit?
    Before you answer: if you combine jquery with require.js then you have widgets. So all that other stuff dojo does and jquery supposedly doesn’t is incorrect. So whats the difference now between dojo and jquery?
    The answer is slightly different widgets have been developed for dojo as slightly different plugins have been developed for jquery.
    So other than variations in the widgets, there is no difference. Toolkit or library or whatever.

    So what is the best?
    The one which gets the job done quicker, and is less performance heavy and easier to maintain and learn. The one which requires less coding, easier to integrate and can work with other technologies and is agnostic giving your flexibility to remove it should you want to.

    Jquery is lighter than dojo, and easier to maintain, and well documented. It utilises the css selectors better than dojo because it has so many ways of accessing a node on the page with multiple selectors, pseudo classes in one request. It’s terse and easier to read and less clunky, ie requires less code to get the job done. Period.

    So if you are used to using dojo, and you are happy with it then fine but don’t say it’s better or that it is a ‘toolkit’ and jquery is a ‘library’, because essentially the do the same thing, but jquery is lighter. Which would you choose? the heavy one, or the light one?

Comments are closed.