我正在构建dojo 1.8.3,其配置文件将所有dojo 和我自己的AMD 代码放在一个层中。我还想在同一个文件中包含一些非 AMD 库(例如 history.js)和 polyfill,原样。是否可以使用 dojo 构建系统来做到这一点?
当前的构建配置文件:
var profile = (function () {
var conf = {
basePath: ".",
layerOptimize: "closure",
optimize: "closure",
cssOptimize: "comments",
mini: true,
selectorEngine: "acme",
defaultConfig: {
hasCache: {
"dojo-built": 1,
"dojo-loader": 1,
"dom": 1,
"host-browser": 1,
"config-selectorEngine": "acme"
},
async: 1
},
packages: [{
name: "dojo",
location: "./dojo"
}, {
name: "dijit",
location: "./dijit"
}, {
name: "dojox",
location: "./dojox"
}, {
name: "MyApp",
location: "./MyApp"
}, {
name: "bootstrap",
location: "./bootstrap"
}],
layers: {
"dojo": {
name: "dojo",
include: [
"dojo/dojo",
"dojo/domReady",
"MyApp/common",
"MyApp/bootstrap"
]
}
}
}
return conf;
}());