-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathpackage.js
More file actions
33 lines (24 loc) · 743 Bytes
/
Copy pathpackage.js
File metadata and controls
33 lines (24 loc) · 743 Bytes
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
var profile = (function () {
var testResourceRe = /^gform\/(tests|mobile|node_modules)\//,
copyOnly = function (filename, mid) {
var list = {
"gform/package.json": 1,
"gform/Gruntfile":1,
"gform/jsdoc-config":1
};
return (mid in list) || (/^gform\/resources\//.test(mid) && !/\.css$/.test(filename)) || /(png|jpg|jpeg|gif|tiff)$/.test(filename);
};
return {
resourceTags: {
test: function (filename, mid) {
return testResourceRe.test(mid);
},
copyOnly: function (filename, mid) {
return copyOnly(filename, mid);
},
amd: function (filename, mid) {
return !testResourceRe.test(mid) && !copyOnly(filename, mid) && /\.js$/.test(filename);
}
}
};
})();