Loading Dojo Library from AOL and Widget Codes from Local?

柔情痞子 提交于 2019-12-05 21:05:41

This may help: http://dojotoolkit.org/forum/dojo-core-dojo-0-9/dojo-core-support/xdomain-usage-dojo-loading-not-detecting-local-modules

The summary is: you need a djConfig item registering the modulePaths you want to be local, and specify a baseUrl to "trick" Dojo into thinking it knows where those paths are relative, across hosts.

djConfig = { modulePaths: { "mine":"/js/mine" };

then you can dojo.require("mine.Thing") from /js/mine/Thing.js

Regards, Peter Higgins

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!