Skip to content

Commit

Permalink
support parallel build
Browse files Browse the repository at this point in the history
  • Loading branch information
Khanh Dao committed Nov 12, 2020
1 parent e1bb244 commit 7ec2545
Showing 1 changed file with 12 additions and 4 deletions.
16 changes: 12 additions & 4 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,22 @@ module.exports = {
name: require('./package').name,

setupPreprocessorRegistry(_type, registry) {
registry.add('htmlbars-ast-plugin', {
name: 'element-helper-syntax',
let pluginObj = this._buildPlugin();
pluginObj.parallelBabel = {
requireFile: __filename,
buildUsing: '_buildPlugin',
params: {},
};
registry.add('htmlbars-ast-plugin', pluginObj);
},

_buildPlugin() {
return {
name: 'element-helper-syntax',
plugin: require('./lib/element-helper-syntax-plugin'),

baseDir: function() {
return __dirname;
}
});
};
}
};

0 comments on commit 7ec2545

Please sign in to comment.