Skip to main content
Checks that elements with role=‘text’ have no focusable descendants
Rule IDa11y/aria-text
CategoryAccessibility
ScopePer-page
Severitywarning
Weight4/10

Solution

Elements with role=‘text’ tell screen readers to treat the content as a single text string. If focusable elements (links, buttons, inputs) are nested inside, screen reader users cannot interact with them properly. Remove role=‘text’ from the parent, or restructure so focusable elements are outside the role=‘text’ container.

Enable / Disable

Disable this rule

squirrel.toml
[rules]
disable = ["a11y/aria-text"]

Disable all Accessibility rules

squirrel.toml
[rules]
disable = ["a11y/*"]

Enable only this rule

squirrel.toml
[rules]
enable = ["a11y/aria-text"]
disable = ["*"]