forked from meteor/meteor
/
package.js
40 lines (38 loc) · 1.13 KB
/
package.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
Package.describe({
summary: "Generates the boilerplate html from program's manifest",
version: '1.1.0'
});
var USE_OLD_BOILERPLATE_GENERATOR = true;
USE_OLD_BOILERPLATE_GENERATOR = false; // uncomment this line to use the new boilerplate generator
if(USE_OLD_BOILERPLATE_GENERATOR){
Package.onUse(function (api) {
api.use([
'underscore',
'spacebars-compiler',
'spacebars',
'htmljs',
'ui',
], 'server');
api.addFiles(['boilerplate-generator-old.js'], 'server');
api.export(['Boilerplate'], 'server');
// These are spacebars templates, but we process them manually with the
// spacebars compiler rather than letting the 'templating' package (which
// isn't fully supported on the server yet) handle it. That also means that
// they don't contain the outer "<template>" tag.
api.addAssets([
'boilerplate_web.browser.html',
'boilerplate_web.cordova.html'
], 'server');
});
} else {
Package.onUse(function (api) {
api.use([
'underscore',
], 'server');
api.addFiles([
'boilerplate_web_template.js',
'boilerplate-generator.js'
], 'server');
api.export(['Boilerplate'], 'server');
});
}