vlad 6f123ff03e 18.07 | 6 年之前 | |
---|---|---|
.. | ||
lib | 6 年之前 | |
.npmignore | 6 年之前 | |
README.md | 6 年之前 | |
package.json | 6 年之前 |
Compile additional export-from statements to ES2015
export * as ns from 'mod';
export v from 'mod';
npm install --save-dev babel-plugin-transform-export-extensions
.babelrc
(Recommended).babelrc
{
"plugins": ["transform-export-extensions"]
}
babel --plugins transform-export-extensions script.js
require("babel-core").transform("code", {
plugins: ["transform-export-extensions"]
});