UNPKG

635 BMarkdownView Raw
1# babel-plugin-react-html-attrs
2
3Transforms JSX `class` attributes into `className` and `for` attributes into `htmlFor`, allowing you to copy and paste HTML into your React components without having to manually edit these particular attributes each time.
4
5## Installation & Usage
6
7Install the plugin:
8
9```
10npm install --save-dev babel-plugin-react-html-attrs
11```
12
13Then edit your .babelrc to include `react-html-attrs`:
14
15```json
16{
17 "plugins": [
18 "react-html-attrs"
19 ]
20}
21```
22
23## Attribution
24
25Testing setup cloned from [gaearon/babel-plugin-react-transform](https://github.com/gaearon/babel-plugin-react-transform).
26
27## MIT Licensed