0.0.2 • Published 3 years ago

babel-plugin-react-add-classname v0.0.2

Weekly downloads
-
License
MIT
Repository
github
Last release
3 years ago

babel-plugin-react-add-classname

babel plugin for to add class name to component

Install

npm:

$ npm install --save-dev babel-plugin-react-add-classname

yarn:

$ yarn add --dev babel-plugin-react-add-classname

Usage

.babelrc

{
  "plugins": ["react-add-classname", { "name": "classname-to-add" }]
}

Options

name

Examples

const hello = () => <div className="test-a hello test-b"></div>

      ↓ ↓ ↓ ↓ ↓ ↓

const hello = () => <div className="test-a hello test-b classname-to-add"></div>

## License

MIT ©