You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+28-29
Original file line number
Diff line number
Diff line change
@@ -47,15 +47,16 @@ _Note: This is experimental and subject to change._
47
47
48
48
The `react` config includes rules which target specific HTML elements. You may provide a mapping of custom components to an HTML element in your `eslintrc` configuration to increase linter coverage.
49
49
50
-
For each component, you may specify a `default` and/or `props`. `default` may make sense if there's a 1:1 mapping between a component and an HTML element. However, if the HTML output of a component is dependent on a prop value, you can provide a mapping using the `props` key. To minimize conflicts and complexity, this currently only supports the mapping of a single prop type.
50
+
By default, these eslint rules will check the "as" prop for underlying element changes. If your repo uses a different prop name for polymorphic components provide the prop name in your `eslintrc` configuration under `polymorphicPropName`.
|[a11y-aria-label-is-well-formatted](docs/rules/a11y-aria-label-is-well-formatted.md)|[aria-label] text should be formatted as you would visual text. | ⚛️ |||
88
-
|[a11y-no-generic-link-text](docs/rules/a11y-no-generic-link-text.md)| disallow generic link text ||| ❌ |
89
-
|[a11y-no-visually-hidden-interactive-element](docs/rules/a11y-no-visually-hidden-interactive-element.md)| Ensures that interactive elements are not visually hidden | ⚛️ |||
90
-
|[array-foreach](docs/rules/array-foreach.md)| enforce `for..of` loops over `Array.forEach`| ✅ |||
|[require-passive-events](docs/rules/require-passive-events.md)| enforce marking high frequency event handlers as passive | 🔍 |||
107
-
|[role-supports-aria-props](docs/rules/role-supports-aria-props.md)| Enforce that elements with explicit or implicit roles defined contain only `aria-*` properties supported by that `role`. | ⚛️ |||
108
-
|[unescaped-html-literal](docs/rules/unescaped-html-literal.md)| disallow unescaped HTML literals | 🔍 |||
|[a11y-aria-label-is-well-formatted](docs/rules/a11y-aria-label-is-well-formatted.md)|[aria-label] text should be formatted as you would visual text. | ⚛️ |||
87
+
|[a11y-no-generic-link-text](docs/rules/a11y-no-generic-link-text.md)| disallow generic link text ||| ❌ |
88
+
|[a11y-no-visually-hidden-interactive-element](docs/rules/a11y-no-visually-hidden-interactive-element.md)| Ensures that interactive elements are not visually hidden | ⚛️ |||
89
+
|[array-foreach](docs/rules/array-foreach.md)| enforce `for..of` loops over `Array.forEach`| ✅ |||
|[require-passive-events](docs/rules/require-passive-events.md)| enforce marking high frequency event handlers as passive | 🔍 |||
106
+
|[role-supports-aria-props](docs/rules/role-supports-aria-props.md)| Enforce that elements with explicit or implicit roles defined contain only `aria-*` properties supported by that `role`. | ⚛️ |||
107
+
|[unescaped-html-literal](docs/rules/unescaped-html-literal.md)| disallow unescaped HTML literals | 🔍 |||
0 commit comments