forked from BenoitZugmeyer/requirejs-hbs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathapp.build.runtime.js
48 lines (38 loc) · 1.01 KB
/
app.build.runtime.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
// This is a build configuration file aimed to use the handlebars-runtime
// library only.
({
baseUrl: "assets",
paths: {
// The handlebars library we include is the runtime one
"handlebars": "lib/handlebars-runtime",
// Let's define the compiler to the full one, so the hbs-builder can
// precompile templates
"handlebars-compiler": "lib/handlebars",
text: "lib/text"
},
hbs: {
templateExtension: ".html"
},
shim: {
handlebars: {
exports: "Handlebars"
},
// Handlebars-compiler needs its shim too.
"handlebars-compiler": {
exports: "Handlebars"
},
},
packages: [
// Include hbs as a package, so it will find hbs-builder when needed
{
name: "hbs",
location: "lib/hbs",
main: "hbs"
}
],
name: "js/main",
// We don't need handlebars-compiler in the final module (we already have
// handlebars-runtime). Exclude it from any module you define.
excludeShallow: ["handlebars-compiler"],
dir: "assets-build"
})