-
Notifications
You must be signed in to change notification settings - Fork 77
/
gridx.profile.js
51 lines (45 loc) · 1.3 KB
/
gridx.profile.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
// from dijit/dijit.profile.js
var profile = (function(){
var testResourceRe = /^gridx\/tests\/|^gridx\/mobile\/tests\//;
var galleryResourceRe = /^gridx\/gallery\//;
var buildResourceRe = /^gridx\/build\//;
var utilResourceRe = /^gridx\/util\/|^gridx\/mobile\/util\//;
var copyOnly = function(filename, mid){
var list = {
"gridx/gridx.profile":1,
"dijit/package.json":1
};
return (mid in list)
|| (/^gridx\/resources\//.test(mid) && !/\.css$/.test(filename))
|| /(png|jpg|jpeg|gif|tiff)$/.test(filename);
};
return {
resourceTags:{
test: function(filename, mid){
return testResourceRe.test(mid)
|| galleryResourceRe.test(mid)
|| buildResourceRe.test(mid)
|| utilResourceRe.test(mid);
},
copyOnly: function(filename, mid){
return copyOnly(filename, mid);
},
amd: function(filename, mid){
return !testResourceRe.test(mid)
&& !galleryResourceRe.test(mid)
&& !buildResourceRe.test(mid)
&& !utilResourceRe.test(mid)
&& !copyOnly(filename, mid)
&& /\.js$/.test(filename);
},
miniExclude: function(filename, mid){
return /^gridx\/bench\//.test(mid)
|| /^gridx\/themes\/themeTest/.test(mid)
|| /^gridx\/mobile\/demos\//.test(mid);
}
},
trees:[
[".", ".", /(\/\.)|(~$)/]
]
};
})();