A label with class and for
- HTML markup
- <label for="email" class="field">Email</label>
Result JSX: <label htmlFor="email" className="field">Email</label>
Elements converted: 1
Attributes renamed: 2
Style strings to objects: 0
Void tags self-closed: 0
Comments wrapped: 0
Top-level elements: 1
- Renamed attributes: for → htmlFor, class → className.
- Inline styles converted to objects: 0.
- Void elements closed with />: 0; comments wrapped as {/* */}: 0.
Both attributes are JavaScript reserved words, so React names them className and htmlFor.