AnsweredAssumed Answered

Boilerplate with CDN - How?

Question asked by MattPil29 on Jun 19, 2013
Latest reply on Jun 21, 2013 by MattPil29

I am trying to use the dojo boilerplate approach to using packages\modules.  I have this working on one site using a downloaded version of the API.  On my next site I want to use a CDN.  Here is what I have:

<div id="map" style="width: 400px; height: 400px;" />   <script src="//"              async="async"              data-dojo-config="async: true, tlmSiblingOfDojo: 0, baseUrl: 'Mapping', isDebug: true, deps:['Mapping/run.js']" ></script>

require({     packages: [         { name: 'esri', location: '' },         'Viewer' ] , ['Viewer']);

define(['require' ], function (require) {          require(["dijit/layout/BorderContainer", "dijit/layout/ContentPane", "esri/map"],     function(BorderContainer, ContentPane, esriMap) {          var map = new esriMap("map", {});      }) });

In the network panel of IE9 I can see bits of dojo loading ok, i.e.

But the request for esri/map is translated to this request:

which returns success but with this response:
Could not find a part of the path 'C:\inetpub\wwwroot\jsapi\arcgis\3.3\map.js\init.js'.

This means that when I debug Viewer\main.js I can see the esriMap variable has not loaded the map code but instead returns the number 3.  Can anyone see where I have gone wrong?

Thanks, Matthew