ARIA role must be appropriate for the element

aria/aria-allowed-role · WCAG 4.1.2 · Level A

ARIA role must be appropriate for the element.

Not all ARIA roles can be applied to all HTML elements. Many elements have implicit roles (e.g., <header> is implicitly banner, <nav> is navigation, <main> is main). Adding an explicit role that matches the implicit role is redundant. Adding a conflicting role breaks semantics. Either remove the role attribute or use a different element.

Scan a page or repo for issues like this · All rules

Introduced in @accesslint/core v0.8.0