jsx-a11y/label-has-associated-control gives error when for is put
TheElegantCoding opened this issue · comments
Luis Monsalve commented
This is my config
'jsx-a11y/label-has-associated-control': 'error'
i am not in react i use "for", this make me error in the code only when i put htmlFor works but i cant do that i dont use react
return (
<>
<label for="email" />
<input id="email" name="email" type="text" />
</>
)
Jordan Harband commented
Most jsx renderers match react, since react invented jsx. It’d be reasonable to add a setting that can rename htmlFor as “for”, i suppose.
Luis Monsalve commented
not all jsx renderes match that, i am in solidjs so yeah it will be nice
Felquis G commented
It's missing aria-label attribute in the label element