Closed
Description
I have a custom switch built with <input type="checkbox">
:
<input
type="checkbox"
role="switch"
:checked="isChecked"
>
After enabling role-has-required-aria-props, the following problem is reported:
Elements with the ARIA role "switch" must have the following attributes defined: aria-checked
I believe this is a false positive. <input type="checkbox">
already has its own checked
, and I'd think we shouldn't need to replace it with aria-checked
. A similar issue was reported for Svelte's ESLint plugin: sveltejs/svelte#7837
Should we consider allowing checked
in place of aria-checked
?