-
Notifications
You must be signed in to change notification settings - Fork 8
/
index.js
36 lines (30 loc) · 901 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
/* eslint-env node */
'use strict';
var path = require('path');
var Funnel = require('broccoli-funnel');
var MergeTrees = require('broccoli-merge-trees');
module.exports = {
name: require('./package').name,
included() {
this._super.included.apply(this, arguments);
this.import('vendor/i18next.js');
this.import('vendor/shims/i18next.js');
this.import('vendor/i18nextXHRBackend.js');
this.import('vendor/shims/i18next-xhr-backend.js');
},
treeForVendor(vendorTree) {
var i18nextTree = new Funnel(
path.dirname(require.resolve('i18next/i18next.js')),
{
files: ['i18next.js'],
}
);
var backendTree = new Funnel(
path.dirname(require.resolve('i18next-xhr-backend/i18nextXHRBackend.js')),
{
files: ['i18nextXHRBackend.js'],
}
);
return new MergeTrees([vendorTree, i18nextTree, backendTree]);
},
};