标签:ret .com mod nod for return type function func
!(function(dependencies, factory) {
//amd || cmd
if (typeof define == ‘function‘ && (define.cmd || define.amd)) {
define(dependencies, function() {
return factory();
});
} else {
var ex = factory();
//CommonJs Nodejs
if (typeof module !== "undefined" && typeof exports === ‘object‘) {
module.exports = ex;
} else {
for (var i in ex) {
window[i] = ex[i];
}
}
}
})([‘jquery‘], function() {
//your code begin
});
https://www.talkingcoder.com/article/6265868891275722752
标签:ret .com mod nod for return type function func
原文地址:http://www.cnblogs.com/Alan2016/p/7062112.html