@proof-ui/a11y-plugin

Uses axe to scan each story against accessibility rules. Violatons are printed to the console, and included in any reports.

Usage no npm install needed!

<script type="module">
  import proofUiA11yPlugin from 'https://cdn.skypack.dev/@proof-ui/a11y-plugin';
</script>

README

@proof-ui/a11y-plugin

Uses axe to scan each story against accessibility rules. Violatons are printed to the console, and included in any reports.

Installation

yarn add -D @proof-ui/a11y-plugin

Usage

// proof.config.js
import A11yPlugin from '@proof-ui/a11y-plugin';

export default {
  plugins: [
    new A11yPlugin({
      // Configuration
    })
  ]
};
# Command Line Usage
proof --a11y

Options

You can configure the A11yPlugin through some options in it's constructor:

Property Description Type Default
config The AXE rule configuration to use when testing a story object (see axe.Spec)
root A selector for the root context when checking for violations string '#root'

Related