broccoli-es6-module-filter
Transpile modules authored in ES6 to other module types.
Installation
npm install --save broccoli-es6-module-filter
Usage (Sample Brocfile.js)
var filterES6Modules = ;var pickFiles = ; module { // say we're creating a third-party component, we'd house our // source code in './lib' var tree = broccoli; // create a CJS version var cjsTree = ; // and AMD var amdTree = ; return cjsTree amdTree;};
And then from the command line:
$ broccoli build output
Options
-
moduleType
-amd
orcjs
-
anonymous
- for amd output, whether or not to name your modules. -
packageName
- for named-amd output, prependspackageName/
to your module names -
main
- for named-amd output, which file is the main entry point of your module that will be returned withrequire(['your-package'])
-
every other option supported by the transpiler