@59naga/babel-plugin-transform-array-from 中文文档教程
babel-plugin-transform-array-from
将 Array.from
替换为 ponyfill 函数。
Installation
npm install @59naga/babel-plugin-transform-array-from --save
Example
In
Array.from('????');
Out
var _arrayFrom = Array.from || function(){...};
_arrayFrom('????');
Usage
Via .babelrc
(Recommended)
.babelrc
{
"plugins": ["@59naga/babel-plugin-transform-array-from"]
}
Via CLI
$ babel --plugins @59naga/babel-plugin-transform-array-from script.js
Via Node API
require("babel-core").transform("code", {
plugins: ["@59naga/babel-plugin-transform-array-from"]
});
Development
要求全局
- NodeJS v0.12.13
- Npm v3.7.1
git clone https://github.com/59naga/@59naga/babel-plugin-transform-array-from
cd @59naga/babel-plugin-transform-array-from
npm install
npm test
License
babel-plugin-transform-array-from
Replace Array.from
with an ponyfill function.
Installation
npm install @59naga/babel-plugin-transform-array-from --save
Example
In
Array.from('????');
Out
var _arrayFrom = Array.from || function(){...};
_arrayFrom('????');
Usage
Via .babelrc
(Recommended)
.babelrc
{
"plugins": ["@59naga/babel-plugin-transform-array-from"]
}
Via CLI
$ babel --plugins @59naga/babel-plugin-transform-array-from script.js
Via Node API
require("babel-core").transform("code", {
plugins: ["@59naga/babel-plugin-transform-array-from"]
});
Development
Requirement global
- NodeJS v0.12.13
- Npm v3.7.1
git clone https://github.com/59naga/@59naga/babel-plugin-transform-array-from
cd @59naga/babel-plugin-transform-array-from
npm install
npm test
License
更多
你可能也喜欢
- 8base-cli 中文文档教程
- @128technology/yinz 中文文档教程
- @5k-rewrite/logger 中文文档教程
- @7span/nuxt-apollo-module 中文文档教程
- @aaa-backend-stack/graphql 中文文档教程
- @aapokiiso/hsl-congestion-route-pattern-repository 中文文档教程
- @aaronpowell/graphql-signalr-subscriptions 中文文档教程
- @abukodonosor/unit 中文文档教程
- @acamp-components/gallery 中文文档教程
- @acciosolutions/images 中文文档教程