DOJO

What is Dojo?
An open source JavaScript toolkit.
Where can you download Dojo?
Dojo web sites:
What are the major parts that Dojo is comprised of?
  • Dojo is the Core and Base package
  • Dijit is the library of the widgets
  • Dojox is the package of Dojo Extensions






How to use Dojo?
  • Load Dojo in the page
  • Load the necessary Dojo styles
  • Use dojo.require statements to include the necessary dojo modules
  • Parse the page to Dojo-enable it (there are couple of ways to do this)
Example (Parsing the page using parseOnLoad in the script tag):









Example (Parsing the page in addOnLoad method):









How to connect the code to dijits?
Code can be connected to the dijits either 1)by using dojo's connect method or 2) by using the <script> elements.
Example (Connecting code to a dijit using dojo's connect method)
<head>




</head>
<body>

</body>
Example (Connecting code to a dijit using <script> elements)
<head>




</head>
<body>

</body>
How to set/get the value of dijit text box?

Advanced DOJO topics:
Following web sites explained VERY WELL the concepts of Writing Modular JavaScript with Dojo and Introduction to Custom Dojo Widgets.