0.0.6 • Published 5 years ago
babel-plugin-teakit v0.0.6
babel-plugin-teakit
A simple transform to cherry-pick teakit modules so you don’t have to.
Example
Transforms
import _ from 'teakit'
const addOne = add(1)
_.map([1, 2, 3], addOne)
To
import _map from 'teakit/map'
const addOne = _add(1)
_map([1, 2, 3], addOne)
Usage
.babelrc
{
"plugins": ["teakit"],
"presets": [["@babel/env", { "targets": { "node": 6 } }]]
}
webpack.config.js
'module': {
'loaders': [{
'loader': 'babel-loader',
'test': /\.js$/,
'exclude': /node_modules/,
'query': {
'plugins': ['teakit'],
'presets': [['@babel/env', { 'targets': { 'node': 6 } }]]
}
}]
}
License
base on babel-plugin-lodash project