1.0.0 • Published 6 years ago

babel-plugin-add-prefix v1.0.0

Weekly downloads
-
License
ISC
Repository
-
Last release
6 years ago

babel-plugin-add-prefix

Compile with prefix

Installation

npm install --save-dev babel-plugin-transform-es2015-destructuring

Usage

Via .babelrc (Recommended)

.babelrc

{
  "plugins": ["babel-plugin-add-prefix"]
}

option:{ { spec: "$", //标识符,默认为"_" func: true, //函数是否添加标识符,默认为true var: true //变量是否添加标识符,默认为true } }

Via Node API

require("babel-core").transform("code", {
  plugins: ["babel-plugin-add-prefix"]
});