1.0.0 • Published 4 years ago
babel-preset-react-optim v1.0.0
babel-preset-react-optim
Babel preset for optimizing react code
Table of Contents
About
This preset is nothing more than a collection of Babel plugins intented to improve the performance of React apps. It is inspired on babel-react-optimize, but customized for my own use cases.
Plugins
- @babel/plugin-transform-react-constant-elements
- @babel/plugin-transform-react-inline-elements
- babel-plugin-transform-react-remove-prop-types
- babel-plugin-transform-remove-console
Usage
In .babelrc
/babel.config.js
:
{
// ...
"env": {
"production": {
"presets": ["babel-preset-react-optim"]
}
}
}
Install
This project uses node and npm.
$ npm install babel-preset-react-optim
$ # OR
$ yarn add babel-preset-react-optim
Contribute
- Fork it and create your feature branch:
git checkout -b my-new-feature
- Commit your changes:
git commit -am "Add some feature"
- Push to the branch:
git push origin my-new-feature
- Submit a pull request
License
MIT
1.0.0
4 years ago