

Dojo JavaScript Toolkit 1.8 Released - Leftium
http://dojotoolkit.org/blog/dojo-1-8-released

======
sahat
What is the fundamental difference between this and jQuery? And why some
random pre-beta MVC javascript frameworks are more popular than Dojo?

~~~
Leftium
"jQuery is primarily a JavaScript library for doing DOM manipulation, Ajax,
events, and effects. Dojo is a more comprehensive toolkit that offers those
same features, but also includes many other pieces that facilitate building
rich web applications, such as patterns for code organization, tools for
abstracting data syncing between server and browser, internationalization,
accessibility, templated widgets, graphing and charting, rich UI widgets, and
much more. Dojo also provides dependency management and build/optimization
tools for creating a production-ready JavaScript application." _Rebecca
Murphey_ [1]

Rebecca also gives a detailed description of her first foray into Dojo coming
from jQuery. [2]

Personally, I think Dojo's lack of good documentation/reference code, lack of
'marketing', and relative complexity keep it from becoming popular. It's much
easier to get started with another library like jQuery because of all these
factors. However, once you get over that initial steep learning curve, Dojo is
great!

[1] [http://www.quora.com/Rebecca-Murphey/answers/Dojo-
JavaScript...](http://www.quora.com/Rebecca-Murphey/answers/Dojo-JavaScript-
toolkit)

[2] [http://rmurphey.com/blog/2009/11/12/dojo-confessions-or-
how-...](http://rmurphey.com/blog/2009/11/12/dojo-confessions-or-how-i-gave-
up-my-jquery-security-blanket-and-lived-to-tell-the-tale/)

 _edit: corrected name to Rebecca_

~~~
dylanks2
Check out the new docs. I think it's no longer reasonable to say Dojo lacks
good docs or reference code.

Marketing is challenging for engineers. We tend to not go crazy over every
small feature, but focus on the big stuff. That said, we're improving our
approach.

~~~
mgkimsal
The tutorial section looks much improved over previous visits - good job.

Two points:

1\. The tutorial shows using the CDN, then there's big warnings saying "don't
do this in production". Give another demonstration of the "highly recommended"
approach vs leaving people to piece that together themselves.

2\. "we tend to not go crazy over every small feature". What's a small feature
to you may just be something that 80 people have been waiting patiently for.
While you can often judge what a 'big' feature is by your standards,
dismissing many other things as 'small' probably misses a lot of people.

~~~
amitu
Point 1. is indeed a "uncomfortable" part of dojo. Getting started is
difficult. For a lot of demo and hello world like apps CDN version is fine,
assuming they are only using the modules packaged into dojo.js on CDN. If you
start using other modules, then you will soon see a escalating number of HTTP
requests, and for this reason using CDN version for production is bad idea.

Its just not that easy to get started with and get a sane production build
from dojo yet. Hope all of this will change by the time 2.0 is out.

------
amitu
One of the best javascript library out there, checkout my work in progress
attempt to port ikog to web while I am learning dojo:
<https://github.com/amitu/ikog>.

I find dojo project way more neater than an equivalent jquery project by
default.

Module systems rock. Real object oriented programming rocks, see how I
extended Pager to make PausePager, this is how object oriented programming was
meant to be. The fact that I can extend any dojo class, and the fact that dojo
comes with a large collection of class, its just too sweet.

I have not yet created a "build", so there are a bit too many http requests
(check work in progress live version here: <http://amitu.com/ikog/>), but I am
hoping after build this issue would be solved.

Lets see how it goes.

~~~
Leftium
Cool! I'm doing a similar port of todo.sh [1] Except when I started I didn't
know about Dojo...

So my next task is to refactor my todo.html into a framework based on Dojo
Boilerplate [2]

I suggest starting with a bare Dojo Boilerplate that builds nicely, then
adding your ikog code to the boilerplate project.

It's more difficult to build later, although you can go a long way with the
online Dojo Web Builder [3]

[1] <https://github.com/Leftium/todo.html>

[2] <https://github.com/Leftium/dojo-boilerplate>

[3] [http://dojotoolkit.org/blog/introducing-the-new-dojo-web-
bui...](http://dojotoolkit.org/blog/introducing-the-new-dojo-web-builder)

~~~
amitu
Thanks for the suggestion, I am looking into boilerplate now.

I like that build.sh in dojo boilerplate "minifies" the html file too!

I checked your todo.sh project, I see the html page, and java loads, but
nothing happens when I type something and press enter in text field. May be
you just started and its not implemented yet, or may be I am doing something
wrong.

My suggestion to you would be to do a hosted version, that syncs to dropbox.
That is my plan for iKog. Parse is good if you do not want to have a
dependency on dropbox, as a storage. Both of these allow me to access todo
list from anywhere, the applet solution does not allow that.

It all depends on what you want to do, for me it is a playing ground to work
with different libraries/services.

------
rhengles
I didn't think much of Dojo previously, but then I had the need to create a
web app with dynamic SVG for the interface, that would be a pain to do with
DOM+CSS. I searched for libraries that could help me, I tried RaphaelJS but
rejected it for the lack of support for the <g> element. In the end the best
library I found is Dojox/GFX, which also can render to SVG, VML, Silverlight
and even Canvas!

I have yet to start producing the app, but Dojo really deserves more
attention.

------
dotborg
Dojo is rather past its prime, because of increasing browser support for CSS3
and HTML5 features. Better support for native language capabilities like
map/reduce/filter/indexOf in arrays also have siginifact impact.

Dojo is my primary js framework, I prefer it over jQuery, because it's more
strict.

------
elchief
I'll just leave this here: <http://maqetta.org/>

~~~
thisisblurry
Aside from the fact that it's hosted by the Dojo Foundation, why?

~~~
elchief
It makes Dojo more compelling.

If you don't think that WYSIWYG IDEs are useful, then that's fine, but some
do, and I thought I'd share.

------
eranation
Nice comeback, I almost forgot Dojo exists but I have to admit, if you put
aside style / coolness, Dojo get's you going out of the box with most UI needs
without searching for plugins, and has a great mobile library

------
hoschi
I tested Sencha, jQuery Mobile and Dojo 1.7 and 1.8 a week ago with my Nexus
phone -> Dojo 1.8 wins clearly when it comes to performace of touch events and
transitions :)

~~~
kyriakos
I read your comment and tested it myself. I was actually very disappointed
with Sencha and especially JQuery Mobile's performance but seems like dojo
actually got it right.

------
nobleach
I am forced to use Dojo whenever I am doing any sort of ESRI Arcgis web map
development. While I agree that there are some nice points in Dojo, I think
it's a travesty the way they were okay with PUKING all over the DOM with their
Dojo specific markup. We have data attributes now, so hopefully they are
beginning to leverage that. The app I'm working on now still uses Dojo 1.7 and
it still has quite a bit of "dojo-this='foo'".

~~~
Leftium
Since version 1.6, "data-dojo-attr='foo'" is preferred; "dojoAttr='foo'" will
not be supported in 2.0 [1][2].

More details: Dojo 1.x to 2.0 migration guide [3]

[1] <http://dojotoolkit.org/features/1.6/html5data-attributes>

[2] [http://dojotoolkit.org/reference-
guide/1.8/releasenotes/1.6....](http://dojotoolkit.org/reference-
guide/1.8/releasenotes/1.6.html)

[3] [http://dojotoolkit.org/reference-
guide/1.8/releasenotes/migr...](http://dojotoolkit.org/reference-
guide/1.8/releasenotes/migration-2.0.html)

