dojo declare correct way
问题 file: dojo/dir1/utils/XmlJsonUtils.js // Author: Rajat Khandelwal define([ "dojo/_base/declare" // declare ], function(declare){ return declare("dir1.utils.XmlJsonUtils",[],{ parseXml : function (xml) { var self=this; var dom = null; if (window.DOMParser) { try { dom = (new DOMParser()).parseFromString(xml, "text/xml"); } catch (e) { dom = null; } } else if (window.ActiveXObject) { try { dom = new ActiveXObject('Microsoft.XMLDOM'); dom.async = false; if (!dom.loadXML(xml)) // parse error ..