babel-plugin-transform-bluebird-co

0.1.3 • Public • Published

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

Via .babelrc (Recommended)

.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

Package Sidebar

Install

npm i babel-plugin-transform-bluebird-co

Weekly Downloads

1

Version

0.1.3

License

MIT

Last publish

Collaborators

  • tony.li