Tuesday, March 31st, 2009
Dojo 1.3 Released along with Plugd
<p>We have been using Dojo 1.3 release candidates for awhile on Bespin, and today the Dojo team released Dojo 1.3 just in time for Internet Explorer 8.1 (really? some people believed that? I know that it isn't quite April Fools......).There are some nice usable APIs added to base such as:
-
-
// create a div.
-
var n = dojo.create("div");
-
-
// create a div with content and styles
-
var n = dojo.create("div", { innerHTML:"hi!", style:{ height:"200px" } });
-
// destroy the node safely
-
dojo.destroy(n);
-
-
// place an anchor somewhere, before the node with id="someNodeId"
-
var a = dojo.create("a", { href:"http://dojotoolkit.org" }, "someNodeId", "before");
-
-
// empty the contents of a node safely:
-
dojo.empty("someNodeId");
-
dojo.query(".nodes").empty();
-
-
// place a new LI in an UL at the first position
-
-
// complex creation in dojo.query. passes through dojo.place
-
dojo.query("#myNode").addContent("hi there!", "first");
-
You can also choose between Acme and Sizzle as the engine that powers dojo.query.
Pete also announced Plugd a very cool plugin that "is available as a standalone "dojo.js" replacement (just throw it in your project on top of dojo.js!) or as a 2k adapter to load a bunch of solid additional base API's. We'll be continually working to merge the best parts of plugd back into Dojo land, but for the time being they are provided as a separate entity, and are fully documented."
With plugd you can write code like this:
-
-
$("p.baz")
-
.appendTo("body")
-
.addClass("bar")
-
.onclick(function(e){
-
e.target.innerHTML = "Wow, JavaScript";
-
});
-
Doesn't look like Dojo does it? :)
I blathered on about this and some other items when I discusses how Alex and Pete kindly indulged me in a scoping exercise that "should never be used in production!" ;)
Related Content:











“Doesn’t look like Dojo does it?”
.
No, it looks like jQuery. :)
No way. Dojo FOR LIFE. Keep up the good work guys – love the framework
All the major libraries have ended up looking like jQuery. Now they just bicker about who is the fastest. Library authors stopped innovating 2-3 years ago.
@deanedwards: I think that’s unfair. While it may be safe to say they’ve centered on largely jQuery-like patterns (though of course there are some big differences), I wouldn’t say they’ve stopped innovating; they’ve simply stopped innovating their APIs, which is a good thing. It means they’re stable APIs.
Where they’re innovating is in the internals, which is bringing real improvements to their users, with little need to change code. That’s a good thing!
I suppose I am being a bit harsh. Sorry JavaScript libraries! :)
Dojo is a great framework, but he has one minus.
I am from Ukraine, and Opera is one of the most widespread browsers
and dojo’s dijit does not support him.
It is a pity.
ignar, I disagree with you completely.
I have quite a complex appl 100% dojo, and FF, Safari and Opera work really good.. In fact, it’s incredible how they manage correctly lots of things.
IE6 and IE7 are quite bad and Chrome is the top bullshit browser.. Really the worst.
But I guess it will depend of your app and what you are using in it.