Skip to content

Commit

Permalink
fix: prevent the jsx-a11y/control-has-associated-label rule from th…
Browse files Browse the repository at this point in the history
…rowing errors on table elements

see jsx-eslint/eslint-plugin-jsx-a11y#959
  • Loading branch information
frantic1048 committed Feb 7, 2025
1 parent 42d16db commit 426bfcd
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
5 changes: 4 additions & 1 deletion packages/eslint-config/src/config/mixin/react.ts
Original file line number Diff line number Diff line change
Expand Up @@ -108,12 +108,15 @@ const config: TSESLint.FlatConfig.ConfigArray = [
controlComponents: [],
ignoreElements: [
'audio',
'video',
'canvas',
'embed',
'input',
'textarea',
'tr',
'video',
// https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/issues/959
'th',
'td',
],
ignoreRoles: [
'grid',
Expand Down
4 changes: 3 additions & 1 deletion specs/eslint-configs/__snapshots__/presets.test.mts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -3878,12 +3878,14 @@ exports[`Resolved config matches snapshot > typescript-react.tsx 1`] = `
"depth": 5,
"ignoreElements": [
"audio",
"video",
"canvas",
"embed",
"input",
"textarea",
"tr",
"video",
"th",
"td",
],
"ignoreRoles": [
"grid",
Expand Down

0 comments on commit 426bfcd

Please sign in to comment.