Skip to content

Commit

Permalink
Enable Babel-parallelization
Browse files Browse the repository at this point in the history
  • Loading branch information
boris-petrov authored and webark committed Nov 12, 2023
1 parent 3a6f95f commit f28e452
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion packages/namespace/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,10 @@ module.exports = {
};
},

_buildPlugin() {
return new NamespaceHelperAst();
},

setupPreprocessorRegistry(type, registry) {
const app = registry.app || this._findHost();

Expand All @@ -37,7 +41,14 @@ module.exports = {
registry.add('css', new NamespaceStyles(options));
registry.add('js', new ColocatedNamespaceObjects(options));

registry.add('htmlbars-ast-plugin', new NamespaceHelperAst());
const pluginObj = this._buildPlugin();

pluginObj.parallelBabel = {
requireFile: __filename,
buildUsing: '_buildPlugin',
};

registry.add('htmlbars-ast-plugin', pluginObj);
},

name: require('./package').name,
Expand Down

0 comments on commit f28e452

Please sign in to comment.