2. What is Dojo Toolkit?
Is a very powerful JavaScript framework that
promises to do everything you need.
http://dojotoolkit.org/
3. What are the features and
resources?
Core:
● Extremely Small and Fast Core
● AMD Modules - Async. Module Definition
● Backward Compatibility
● Powerful Base APIs
4. What are the features and
resources?
● Dijit - Dojo's world class widget library
● dgrid and Dojox - to data grids
● Mobile - Rich Interface Elements
● Dojo GFX - Graphics, Charting and
Visualization
5. Getting Started
● Including the library
With Google CDN
<script src="//ajax.googleapis.com/ajax/libs/dojo/1.8.1/dojo/dojo.
js" data-dojo-config="async: true"></script>
6. Getting Started
● Including the library
Local library
<script src="../dojo/dojo.js"
data-dojo-config="async: true"></script>
7. Getting Started
● Including AMDs
// Require the module we just created
require(["demo/myModule"], function(myModule){
// Use our module to change the text in the greeting
myModule.setText("greeting", "Hello Dojo!");
// After a few seconds, restore the text to its original state
setTimeout(function(){
myModule.restoreText("greeting");
}, 3000);
});
8. Getting Started
● Waiting the DOM
require(["dojo/dom", "dojo/domReady!"], function
(dom){
var greeting = dom.byId("greeting");
greeting.innerHTML += " from Dojo!";
});
9. Getting Started
● Adding Visual Effects
require(["dojo/dom", "dojo/fx", "dojo/domReady!"], function(dom,
fx){
var greeting = dom.byId("greeting");
greeting.innerHTML += " from Dojo!";
fx.slideTo({
top: 100,
left: 200,
node: greeting
}).play();
});