|
hace 5 años | |
---|---|---|
.. | ||
.test | hace 5 años | |
lib | hace 5 años | |
src | hace 5 años | |
.npmignore | hace 5 años | |
LICENSE | hace 5 años | |
PATENTS | hace 5 años | |
README.md | hace 5 años | |
package.json | hace 5 años |
Transform async/generator functions with regenerator
$ npm install babel-plugin-transform-regenerator
.babelrc
(Recommended).babelrc
// without options
{
"plugins": ["transform-regenerator"]
}
// with options
{
"plugins": [
["transform-regenerator", {
asyncGenerators: false, // true by default
generators: false, // true by default
async: false // true by default
}]
]
}
$ babel --plugins transform-regenerator script.js
require("babel-core").transform("code", {
plugins: ["transform-regenerator"]
});