This command line application runs axe-core accessibility checks against html files or urls.
It can return a report of accessibility problems or write the fixed html to a new or existing local file.
(if you are looking for the curated version of the plug-in please click here)
Setup the application:
npm run setupRun the linter(s):
npm run lintReport violation(s) for the example-file:
node src/cli.js report example.htmlFix violation(s) for the example-file:
node src/cli.js fix example.html example-fixed.htmlReview the help to see various options
$ node src/cli.js -h
$ node src/cli.js fix -h
$ node src/cli.js report -hFlags:
- Global
-r, --rules <rules>Only run checks or fixes against this list of comma separated rule id's. Example:-r "button-name, valid-lang"
fix-p, --previewPrint the fixed html to the console. When using this rule a target file does not need to be specified.
report-j, --jsonPrint the raw Axe violation json data instead of the human readable version.