Is there a way display jimu dijit tools (like DrwaBox, symbolPicker) in declarative way as shown below without using dojo's parser.parse() function ? my dojoConfig.parseOnLoad is set to true.
<div data-dojo-attach-point="drawBox" data-dojo-type="jimu/dijit/DrawBox" data-dojo-id="drawBox" ></div>
Solved! Go to Solution.
Mouli,
You should NOT use parser.parse or dojoConfig.paseOnLoad. The parsing of dijit is already handles by the WAB core. If you add a jimu dijit to your widgets template html then make sure you also include the require for that dijit in your widget.js file as well. You will also need to include the 'dijit/_WidgetsInTemplateMixin' require and var _WidgetsInTemplateMixin and add _WidgetsInTemplateMixin to the declare line
return declare([BaseWidget, _WidgetsInTemplateMixin], {
Mouli,
You should NOT use parser.parse or dojoConfig.paseOnLoad. The parsing of dijit is already handles by the WAB core. If you add a jimu dijit to your widgets template html then make sure you also include the require for that dijit in your widget.js file as well. You will also need to include the 'dijit/_WidgetsInTemplateMixin' require and var _WidgetsInTemplateMixin and add _WidgetsInTemplateMixin to the declare line
return declare([BaseWidget, _WidgetsInTemplateMixin], {
Thanks Robert.