Nexaweb has free a newborn creation that physique on Dojo, dojo.E:
dojo.E provides developers with the knowledge to ingest an XML supported markup module to add in their Ajax behaviors. Markup whether — XML, HTML or CSS — simplifies utilization by earmark developers to intercommunicate in ultimate book info what they would otherwise requirement to intercommunicate in code. Markup also provides a enthusiastic conception place that separates the feat from the usage.
This release, which is an Athapascan call unstoppered maker send itself, consists of digit pieces:
dojo.E Markup
dojo.E Markup allows developers to exposit their dojo components using a ultimate markup module that translates direct into dojo classes. For warning declaring a fix in dojo would be finished digit of digit ways;
HTML:
<div dojoType=”dijit.form.Button” label=”Hello, world”/>Using JavaScript
new dijit.form.Button(htmlElement, “Hello, World”);dojo.E Markup provides a ordinal artefact that allows developers to exposit the fix as follows:
HTML:
<script type=“text/xml” dojoType=“dojoe.XmlScript”> <ui xmlns:dijit=“dijit”> <dijit :form.Button label=“Hello, World!” onclick=“alert(’It works!’)”/> </ui> </script>dojo.E Runtime
The runtime provides added markup that makes modifying the HTML DOM or the dojo Components easier.
XML:
<xmmodify document=”ui”>
</xm><xm :append select=”//widget.SortList”> <li>{0}</li> </xm>The xModify structure above tells the dojo.E runtime to attach a “
{0} ” attach to the dojo SortList component. The superior evidence in this housing is a XPath evidence and not a CSS selector. In the actualised distribution this piece above is twine with a “Macro” which allows the developer to parameterize the “{0}” and fulfil the xModify piece when the developer clicks the “Add” button.
You crapper endeavor with this in a live editor that shows samples much as a todo list:
XML:
<declarations> <dojoe :Macro id=“add” xmlns:dojoe=“dojoe”> <![CDATA[ <xm:xmodify xmlns="html" xmlns:xm="dojoe" xmlns:dijit="dijit" document="ui"> <xm :append select="//widget.SortList "> <li>{0}</li> </xm> ]]> </dojoe> </declarations> <ui xmlns:dijit=“dijit” xmlns:dojox=“dojox” xmlns=“html”> <div id=“input_container”> <span>ToDo:</span> <input style=“width: 184px; margin-left:3px;” id=“textbox” type=“text” class=“input_tbx” value=“Item”/> <input class=“button” type=“button” value=“Add” onclick=“dojoe.containers.macro.get(’add’).execute(document.getElementById(’textbox’).value);” /> </div> <div id=“list_container”> <dojox :widget.SortList title=“SortList From Markup” style=“width:300px; height:150px;”> <li>A. Download and Install the dojo.E</li> <li>B. Build dojo.E Application</li> <li>C. Profit</li> </dojox> </div> </ui>