Replies: 1 comment 1 reply
-
|
Totally in favour of this proposal! I have a special spot for a11y, so any improvement that we can land for better DX, it's very welcome from me! Regarding WPT, I wonder if we can do something like we do for conformance tests. We can use git submodules, and pull the tests we need. It will require a testing suite dedicated to it If that's not feasible, we could have a script that pulls those tests in a special folder, and then we run |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Summary
I’d love to make Biome the best accessibility lint configuration out-of-the-box, where folks instantly get the most accurate information and guidance they can get. In my research working on accessibility and the ARIA spec very closely, I think there are 2 major “projects” that each could contribute some significant improvements toward that goal (with both projects feeding into one another).
Project 1. Spec expansion
Currently, Biome supports the core specifications, but is missing a few key ones:
rolecalculation*Accname also used for role calculation
These missing specs responsible for role calculation and accessible name computation. Without these, Biome will interpret HTML elements differently than a browser does which can lead to bad advice.
Of course with enough users these days, it’s still probably in the realm where the most common scenarios are covered. But there are still thousands of papercuts where people are having to either disable a11y lint rules in some scenarios, or outright turn them off. I’d love if folks could just operate with everything on ❤️
Tip
Proposal: add the missing specs here to improve ARIA role calculation which improves lint rule guidance
Project 2. WPT suite
When it comes to testing the accuracy of accessible libraries, there’s perhaps no better resource than the Web Platform Tests (WPT) project, which boasts a staggering number of test cases that test all manner of things. It’s so expansive that it’s rare for any software to get 100% passing tests. But it’s great at showing where all the gaps are.
Specifically, I think these tests are most relevant to Biome’s a11y rules:
Even if Biome is passing some of these tests, even just pulling them in can prevent future bugs from popping up which is worth the effort.
Tip
Proposal: find some way to import Web Platform Tests into the existing test suite, or find some way to convert them into Rust (which isn’t the craziest idea—test cases theoretically should never change, and though this project is expansive it also doesn’t update at breakneck speed)
Impact
Biome currently has
35a11y lint rules today, and 59 open issues that mention accessibility. These improvements would reduce a lot of accessibility-related bugs and improve the existing linting setup. I do think that for the number of issues opened, there are a lot more lint rules being ignored or disabled going unreported. Or worse—folks are adjusting accessible UIs to follow slightly-incorrect advice.Questions
Really just a conversation starter to see if any other folks are interested in something similar, or have done work in this area.
Beta Was this translation helpful? Give feedback.
All reactions