Rules
All ESLint rules provided by eslint-plugin-react-a11y
36 Rules Available
React accessibility rules for WCAG compliance.
All Rules
| Rule | 🧠 | 💼 | 🔧 | 💡 | ⚠️ | Docs |
|---|---|---|---|---|---|---|
| alt-text Enforce alt text on images with accessibility impact context | 🟢 | |||||
| anchor-ambiguous-text Enforce that anchor text is not ambiguous | 🟢 | |||||
| anchor-has-content Enforce that anchors have content | 🟢 | |||||
| anchor-is-valid Enforce that anchors are valid, navigable elements | 🟢 | |||||
| aria-activedescendant-has-tabindex Enforce that elements with aria-activedescendant have proper tabindex | 🟢 | |||||
| aria-props Enforce that ARIA attributes are valid | 🟢 | |||||
| aria-role Enforce that elements with ARIA roles have valid values | 🟢 | |||||
| aria-unsupported-elements Enforce that elements that don't support ARIA roles, states, and properties do not contain them | 🟢 | |||||
| autocomplete-valid Enforce that autocomplete attribute has valid value | 🟢 | |||||
| click-events-have-key-events Enforce that onClick is accompanied by keyboard events | 🟢 | |||||
| control-has-associated-label Enforce that controls (interactive elements) have associated labels | 🟢 | |||||
| heading-has-content Enforce that headings have content | 🟢 | |||||
| html-has-lang Enforce that html element has lang attribute | 🟢 | |||||
| iframe-has-title Enforce that iframes have a title attribute | 🟢 | |||||
| img-redundant-alt Enforce img alt attribute does not contain redundant words | 🟢 | |||||
| interactive-supports-focus Enforce that elements with interactive handlers are focusable | 🟢 | |||||
| label-has-associated-control Enforce that labels have accessible controls | 🟢 | |||||
| lang Enforce that lang attribute has a valid value | 🟢 | |||||
| media-has-caption Enforce that media elements have captions | 🟢 | |||||
| mouse-events-have-key-events Enforce that onMouseOver/onMouseOut are accompanied by onFocus/onBlur | 🟢 | |||||
| no-access-key Enforce that accessKey attribute is not used | 🟢 | |||||
| no-aria-hidden-on-focusable Enforce that aria-hidden="true" is not used on focusable elements | 🟢 | |||||
| no-autofocus Enforce that autoFocus prop is not used on elements | 🟢 | |||||
| no-distracting-elements Enforce that distracting elements are not used | 🟢 | |||||
| no-interactive-element-to-noninteractive-role Enforce that interactive elements don't have non-interactive ARIA roles | 🟢 | |||||
| no-keyboard-inaccessible-elements Detects clickable divs without keyboard support | 🟢 | |||||
| no-missing-aria-labels Detects elements missing ARIA labels | 🟢 | |||||
| no-noninteractive-element-interactions Enforce that non-interactive elements don't have interactive handlers | 🟢 | |||||
| no-noninteractive-element-to-interactive-role Enforce that non-interactive elements don't have interactive ARIA roles | 🟢 | |||||
| no-noninteractive-tabindex Enforce that non-interactive elements do not have tabindex | 🟢 | |||||
| no-redundant-roles Enforce that explicit roles don't repeat implicit roles | 🟢 | |||||
| no-static-element-interactions Enforce that static elements don't have interactive handlers | 🟢 | |||||
| prefer-tag-over-role Enforce semantic DOM elements over ARIA role properties | 🟢 | |||||
| role-has-required-aria-props Enforce that elements with ARIA roles have all required ARIA attributes | 🟢 | |||||
| role-supports-aria-props Enforce that elements with roles contain only supported ARIA properties | 🟢 | |||||
| scope Enforce that scope prop is only used on th elements | 🟢 | |||||
| tabindex-no-positive Enforce that tabIndex is not positive | 🟢 |
Building secure JavaScript with Interlace? Star the repo to get new rules and CWE coverage as we ship them — or follow the AI-code-security benchmarks behind them.