Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 15 additions & 1 deletion docs/dom-testing-library/api-helpers.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,8 @@ for other popular assertion libraries:

- [chai-dom](https://github.com/nathanboktae/chai-dom)

If you're aware of some other alternatives, please [make a pull request](https://github.com/testing-library/testing-library-docs/pulls)
If you're aware of some other alternatives, please
[make a pull request](https://github.com/testing-library/testing-library-docs/pulls)
and add it here!

## `getNodeText`
Expand Down Expand Up @@ -185,6 +186,19 @@ console.log(getRoles(nav))
// }
```

## `isInaccessible`

This function will compute if the given element should be excluded from the
accessibility API by the browser. It implements every **MUST** criteria from the
[Excluding Elements from the Accessibility Tree](https://www.w3.org/TR/wai-aria-1.2/#tree_exclusion)
section in WAI-ARIA 1.2 with the exception of checking the `role` attribute.

It is defined as:

```typescript
function isInaccessible(element: Element): boolean
```

## Debugging

When you use any `get` calls in your test cases, the current state of the
Expand Down