babel-plugin-transform-bluebird-co
replace co with bluebird-co(high performace co) ă replace Promise with bluebird plugin.
This plugin is aiming to transform base Promiseăasync/awaităco
to high performace BluebirdăBluebird.coroutineăbluebird-co
.So the suggest usage is use this plugin along with transform-async-to-module-method
;
Installation
npm install bluebird bluebird-co --save
npm install babel-plugin-transform-bluebird-co babel-plugin-transform-async-to-module-method --save-dev
Usage
.babelrc
(Recommended)
Via .babelrc
{
"plugins": [
"transform-bluebird-co",
[
"transform-async-to-module-method",
{
"module": "bluebird-co",
"method": "coroutine"
}]
]
}
Development
Requirement global
- NodeJS v5.11.0
- Npm v3.8.6
git clone https://github.com/libotony/babel-plugin-transform-bluebird-co
cd babel-plugin-transform-bluebird-co
npm install
npm test
Thanks
babel-plugin-transform-bluebird
License
MIT