-
Notifications
You must be signed in to change notification settings - Fork 33
Add AccessLint scan engine #241
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
kzhou314
wants to merge
13
commits into
main
Choose a base branch
from
accesslint-engine-prototype
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+176
−15
Open
Changes from all commits
Commits
Show all changes
13 commits
Select commit
Hold shift + click to select a range
52e401a
Add AccessLint scan engine
kzhou314 d07f5eb
Document AccessLint engine in README
kzhou314 41f49ec
Apply suggestions from code review (escape AccessLint solutionShort a…
kzhou314 0432b26
Fix formatting
kzhou314 2cdf7c1
Merge remote-tracking branch 'origin/main' into accesslint-engine-pro…
kzhou314 61c5831
Merge remote-tracking branch 'origin/main' into accesslint-engine-pro…
kzhou314 e1aed69
Merge branch 'main' into accesslint-engine-prototype
kzhou314 ef9b812
Pin Playwright to 1.60.0 to keep the integration-test Chromium unchanged
kzhou314 d065c0c
Add axe vs. AccessLint comparison doc
kzhou314 296fa7e
Trim axe vs. AccessLint doc
kzhou314 52cc0db
List AccessLint-only checks and tighten wording in comparison doc
kzhou314 4853746
Merge branch 'main' into accesslint-engine-prototype
kzhou314 600734b
Update AXE_VS_ACCESSLINT.md
kzhou314 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,45 @@ | ||
| # axe vs. AccessLint | ||
|
|
||
| The a11y scanner ships two built-in scan engines: [axe-core](https://github.com/dequelabs/axe-core) (the default) and [AccessLint](https://github.com/AccessLint/accesslint), a newer, lightweight ruleset. Both run against the live page and report WCAG violations, and the two mostly overlap. axe is the mature, well-documented baseline; AccessLint adds a small set of checks axe doesn't run by default. This document covers what's different and provides advice on which to enable. | ||
|
|
||
| > 👉 Pick engines with the `scans` input. They run independently and file their findings as separate issues. | ||
|
|
||
| ## Three ways to run | ||
|
|
||
| | `scans` | Runs | Best when | | ||
| | ------------------------ | --------------- | -------------------------------------------------------------------------------------------------- | | ||
| | _(omitted)_ or `["axe"]` | axe only | the mature default; lowest noise | | ||
| | `["accesslint"]` | AccessLint only | you want AccessLint's extra checks without axe's duplicates, but you give up axe's maturity and Deque docs | | ||
| | `["axe","accesslint"]` | both | maximum coverage, at the cost of duplicate findings | | ||
|
|
||
| ## At a glance | ||
|
|
||
| | | axe-core | AccessLint | | ||
| | ----------------- | --------------------------------------------------------------------------------------- | -------------------------------------------------------------------- | | ||
| | **Strength** | Mature, widely adopted, well-documented baseline | Lightweight second pass; adds a few checks axe doesn't run by default | | ||
| | **Coverage** | WCAG 2.0/2.1/2.2 (A/AA/AAA) tags plus best practices; some 2.2 rules are off by default | WCAG 2.2 A/AA plus best-practice rules | | ||
| | **Per-rule docs** | Deque University help URL on every finding | Rule IDs + messages; less rich public per-rule docs | | ||
| | **Main risk** | Doesn't catch every WCAG issue automatically (~57%) | Newer and less battle-tested; smaller ecosystem | | ||
|
|
||
| Both cover the same large core: alt text, link/button names, form labels, ARIA validity, heading order, landmarks, table headers, language attributes, and color contrast. | ||
|
|
||
| ## What AccessLint adds | ||
|
|
||
| The engines share most of their rules (AccessLint ships ~93, axe ~104, and the bulk map to the same checks). Measured against the scanner's **default** axe run, these are the only AccessLint checks with no axe rule that fires. See the [AccessLint rules reference](https://github.com/AccessLint/accesslint/blob/main/core/README.md#rules-1) for the full catalog. | ||
|
|
||
| **No axe rule covers these:** | ||
|
|
||
| - **Visible focus indicator** (2.4.7 AA) — `keyboard-accessible/focus-visible`: focusable elements must show a visible focus indicator. | ||
| - **Accessible authentication** (3.3.8 AA) — `input-assistance/accessible-authentication`: password fields must not block password managers / paste. | ||
| - **Generic alt wording** — `text-alternatives/image-alt-words`: alt text shouldn't be "image", "photo", etc. (axe only flags alt that _duplicates adjacent text_). | ||
| - **Presentational element with focusable children** — `aria/presentational-children-focusable` (adjacent to axe's `presentation-role-conflict`, but a separate check). | ||
|
|
||
| **axe has the rule, but only as _experimental_, so the scanner's default run skips it:** | ||
|
|
||
| - **Orientation lock** (1.3.4 AA) — `adaptable/orientation-lock` ↔ axe `css-orientation-lock`. | ||
| - **Paragraph styled as a heading** — `navigable/p-as-heading` ↔ axe `p-as-heading`. | ||
| - **Accessible name missing visible label text** (2.5.3) — `labels-and-names/label-content-mismatch` ↔ axe `label-content-name-mismatch`. | ||
| - **Focusable element without a semantic role** — `keyboard-accessible/focus-order` ↔ axe `focus-order-semantics`. | ||
| - **Large-table data cell without a header** — `adaptable/td-has-header` ↔ axe `td-has-header`. | ||
|
|
||
| Everything else overlaps. Even where rule IDs differ the checks coincide — e.g. 1.4.12 text spacing (axe's single `avoid-inline-spacing` vs AccessLint's `letter-spacing` / `line-height` / `word-spacing`) and 1.2.1 audio (axe `audio-caption` vs AccessLint `audio-transcript`). |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.