You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
27 lines
500 B
27 lines
500 B
2 years ago
|
# scope
|
||
|
|
||
|
The `scope` prop should be used only on `<th>` elements.
|
||
|
|
||
|
## Rule details
|
||
|
|
||
|
This rule takes no arguments.
|
||
|
|
||
|
### Succeed
|
||
|
```jsx
|
||
|
<th scope="col" />
|
||
|
<th scope={scope} />
|
||
|
```
|
||
|
|
||
|
### Fail
|
||
|
|
||
|
```jsx
|
||
|
<div scope />
|
||
|
```
|
||
|
|
||
|
## Accessibility guidelines
|
||
|
- [WCAG 1.3.1](https://www.w3.org/WAI/WCAG21/Understanding/info-and-relationships)
|
||
|
- [WCAG 4.1.1](https://www.w3.org/WAI/WCAG21/Understanding/parsing)
|
||
|
|
||
|
### Resources
|
||
|
- [axe-core, scope-attr-valid](https://dequeuniversity.com/rules/axe/3.5/scope-attr-valid)
|