forked from ember-animation/liquid-fire
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.js
38 lines (31 loc) · 1.01 KB
/
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
38
/*jshint node: true */
'use strict';
var checker = require('ember-cli-version-checker');
var path = require('path');
var mergeTrees = require('broccoli-merge-trees');
var pickFiles = require('broccoli-static-compiler');
module.exports = {
name: 'liquid-fire',
init: function() {
checker.assertAbove(this, '0.2.0');
},
treeForVendor: function(tree){
var velocityPath = path.dirname(require.resolve('velocity-animate'));
var velocityTree = pickFiles(this.treeGenerator(velocityPath), {
srcDir: '/',
destDir: 'velocity'
});
return mergeTrees([tree, velocityTree]);
},
included: function(app){
app.import('vendor/velocity/velocity.js');
app.import('vendor/liquid-fire.css');
},
setupPreprocessorRegistry: function(type, registry) {
var TransformLiquidWithAsToHash = require('./ext/plugins/transform-liquid-with-as-to-hash');
registry.add('htmlbars-ast-plugin', {
name: "transform-liquid-with-as-to-hash",
plugin: TransformLiquidWithAsToHash
});
}
};