Better eslint a11y rule defaults
See original GitHub issueSummary
The default a11y eslint rules are all defined as “warn”. This is okay for most rules but for the newly added “jsx-a11y/control-has-associated-label” rule, adding “warn” is making it almost unusable.
Even the following is flagged by eslint 🤔 :
<label>lovely label<input type="text/></label>
The recommended config for this rule is much more sane.
Would you accept a PR to fix this?
Issue Analytics
- State:
- Created 3 years ago
- Comments:8 (7 by maintainers)
Top Results From Across the Web
Using ESLint Plugin jsx-a11y With Recommended and ...
Customizing rules with warn is a way to disable recommended rules. jsx-a11y Docs, NPM, and Rules List. The documentation is extensive and ...
Read more >12 essential ESLint rules for React - LogRocket Blog
This rule is good at finding potential dependency-related bugs, but there are some limitations: By default, custom Hooks with dependency arrays ...
Read more >Working with Rules - ESLint - Pluggable JavaScript Linter
"suggestion" means the rule is identifying something that could be done in a better way but no errors will occur if the code...
Read more >Set up ESLint to Audit Accessibility Issues in React | egghead.io
This should include adding static analysis checking for common accessibility standards and best practices. We can get this with the latest eslint plugin:...
Read more >eslint-plugin-react-native-a11y - Formidable Labs
Eslint -plugin-react-native-a11y is a collection of React Native specific ESLint rules for identifying accessibility issues. Building upon the foundation set ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I think this case may be relevant to you: custom component
It looks like by supplying that to the config it will then validate the rendered input (that Formik will produce) against the label
Since this change, I noticed I’m getting warnings for the rule when using in combination with the Formik <Field> tag.
No warning
Get warning
Both approaches produce the same HTML output. Is there a way to address that?