Skip to content
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

[eslint-config-airbnb] jsx-a11y/control-has-associated-label config does not ignore td and th HTML elements #3069

Open
ZeeshanTamboli opened this issue Dec 7, 2024 · 4 comments

Comments

@ZeeshanTamboli
Copy link

ZeeshanTamboli commented Dec 7, 2024

At Material UI, we use eslint-config-airbnb, which includes jsx-a11y pre-defined rules. We’re encountering this error for td and th elements:

A control must be associated with a text label  jsx-a11y/control-has-associated-label

Since td and th are non-interactive, they should be added to the ignoreElements list here and not parsed by jsx-a11y plugin.

This is preventing us from bumping eslint-plugin-jsx-a11y: mui/material-ui#39752.

@ljharb
Copy link
Collaborator

ljharb commented Dec 8, 2024

It shouldn’t be preventing anything since you can (and should, in cases like these) be overriding a rule’s config whenever needed.

The change seems good, however.

@AyushSinha-6409

This comment was marked as off-topic.

@ljharb

This comment was marked as off-topic.

@AyushSinha-6409

This comment was marked as off-topic.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants