-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.js
37 lines (28 loc) · 973 Bytes
/
index.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
'use strict';
module.exports = {
name: require('./package').name,
// eslint-disable-next-line no-unused-vars
included(_app) {
this._super.included.apply(this, arguments);
const vendorPath = 'vendor/air-datepicker';
this.import(`${vendorPath}/air-datepicker.js`);
this.import(`${vendorPath}/air-datepicker.css`);
},
// eslint-disable-next-line no-unused-vars
treeForVendor(_defaultTree) {
const Funnel = require('broccoli-funnel');
const mergeTrees = require('broccoli-merge-trees');
const path = require('path');
const distPath = path.dirname(require.resolve('air-datepicker'));
let browserVendorLib = new Funnel(distPath, {
destDir: 'air-datepicker',
files: ['air-datepicker.js'],
});
let defaultCSS = new Funnel(distPath, {
destDir: 'air-datepicker',
include: ['air-datepicker.css'],
});
let nodes = [browserVendorLib, defaultCSS];
return new mergeTrees(nodes);
},
};