-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathember-cli-build.js
80 lines (69 loc) · 2.87 KB
/
ember-cli-build.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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
/* eslint-env node */
const EmberApp = require('ember-cli/lib/broccoli/ember-app');
module.exports = function(defaults) {
var app = new EmberApp(defaults, {
'ember-cli-babel': {
includePolyfill: true
},
// Add options here
emberCliFontAwesome: {
useScss: true
}
});
// Use `app.import` to add additional libraries to the generated
// output files.
//
// If you need to use different assets in different
// environments, specify an object as the first parameter. That
// object's keys should be the environment name and the values
// should be the asset to use in that environment.
//
// If the library that you are including contains AMD or ES6
// modules that you would like to import into your application
// please specify an object with the list of modules as keys
// along with the exports of each module as its value.
// Bootstrap and tether requirement
app.import(app.bowerDirectory + '/tether/dist/js/tether.js');
app.import(app.bowerDirectory + '/bootstrap/dist/js/bootstrap.js');
// Bootbox
app.import(`${app.bowerDirectory}/bootbox/bootbox.js`);
app.import('vendor/shims/bootbox.js');
// adds iframe transport support to jQuery.ajax()
app.import(`${app.bowerDirectory}/blueimp-file-upload/js/jquery.iframe-transport.js`);
/* The basic fileupload plugin - it enhances the file upload process,
but doesn't make any assumptions about the user interface or the
content-type of the response. */
app.import(`${app.bowerDirectory}/blueimp-file-upload/css/jquery.fileupload.css`);
app.import(`${app.bowerDirectory}/blueimp-file-upload/js/vendor/jquery.ui.widget.js`);
app.import(`${app.bowerDirectory}/blueimp-file-upload/js/jquery.fileupload.js`);
// extends the basic version of the fileupload plugin and adds file processing functionality.
app.import(`${app.bowerDirectory}/blueimp-file-upload/js/jquery.fileupload-process.js`);
// extends the file processing plugin and adds file validation functionality.
app.import(`${app.bowerDirectory}/blueimp-file-upload/js/jquery.fileupload-validate.js`);
// SPARQL parser for javascript
app.import(`vendor/sparqljs/sparqljs-browser.js`, {
using: [
{ transformation: 'amd', as: 'sparqljs' }
]
});
// CodeMirror + YASGUI-YASQE
// TODO: Import YASQE without a jquery bundle
app.import({
development: `${app.bowerDirectory}/yasgui-yasqe/dist/yasqe.bundled.js`,
production: `${app.bowerDirectory}/yasgui-yasqe/dist/yasqe.bundled.min.js`
}, {
using: [
{ transformation: 'amd', as: 'yasqe' }
]
});
// Download.js is used for downloading files from javascript
app.import('bower_components/downloadjs/download.js');
// Openlayers 3
app.import({
development: 'vendor/ol/ol-debug.js',
production: 'vendor/ol/ol.js'
});
app.import('vendor/ol/ol.css');
app.import('vendor/shims/ol.js');
return app.toTree();
};