The TanStack Devtools Accessibility (A11y) Plugin provides real-time accessibility auditing for your web applications, powered by axe-core. It helps you identify and fix accessibility issues during development.
npm install @tanstack/devtools-a11y
# or
pnpm add @tanstack/devtools-a11y
# or
yarn add @tanstack/devtools-a11y
import { createRoot } from 'react-dom/client'
import { TanStackDevtools } from '@tanstack/react-devtools'
import { a11yDevtoolsPlugin } from '@tanstack/devtools-a11y/react'
createRoot(document.getElementById('root')!).render(
<>
<App />
<TanStackDevtools plugins={[a11yDevtoolsPlugin()]} />
</>,
)
import { render } from 'solid-js/web'
import { TanStackDevtools } from '@tanstack/solid-devtools'
import { a11yDevtoolsPlugin } from '@tanstack/devtools-a11y/solid'
render(
() => (
<>
<App />
<TanStackDevtools plugins={[a11yDevtoolsPlugin()]} />
</>
),
document.getElementById('root')!,
)
import { createA11yDevtoolsVuePlugin } from '@tanstack/devtools-a11y/vue'
const plugins = [createA11yDevtoolsVuePlugin()]
When you click on an issue in the panel, the plugin will:
This makes it easy to locate and inspect issues directly on the page.
Initial configuration can be provided via the vanilla plugin API:
import { createA11yPlugin } from '@tanstack/devtools-a11y'
const plugin = createA11yPlugin({
threshold: 'serious',
ruleSet: 'wcag21aa',
showOverlays: true,
persistSettings: true,
disabledRules: [],
})
Common options fields:
If you don't need to provide initial configuration, you can use the framework plugin helpers directly (the settings UI persists changes to localStorage by default).
Issues are categorized by impact level with corresponding overlay colors:
| Impact | Color | Description |
|---|---|---|
| Critical | Red | Must be fixed - prevents users from accessing content |
| Serious | Orange | Should be fixed - significantly impacts user experience |
| Moderate | Yellow | Consider fixing - affects some users |
| Minor | Blue | Optional improvement - minor impact |
The panel UI is implemented in Solid and wrapped for React, Solid, Preact, and Vue using @tanstack/devtools-utils.
import { exportToJSON } from '@tanstack/devtools-a11y'
const jsonString = exportToJSON(auditResult)
import { exportToCSV } from '@tanstack/devtools-a11y'
const csvString = exportToCSV(auditResult)
The plugin supports the following accessibility standards:
See the full working example at: examples/react/a11y-devtools/
Run it with:
cd examples/react/a11y-devtools
pnpm dev