| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
✅ Deploy Preview for testing-library ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
Sorry, something went wrong.
| <body> | ||
| <section> | ||
| <button disabled>Login</button> | ||
| <div role="alert" aria-disabled="false">Failed to login</button> |
There was a problem hiding this comment.
Having the aria-disabled here seems a bit confusing to me.
Are we also filtering by aria-disabled or just by the disabled attribute? I think that we should explain it here so people will have a clear understanding.
Sorry, something went wrong.
There was a problem hiding this comment.
We're filtering by things that are disabled according to the a11y tree. This applies to every filter option in ByRole.
This here includes examples.
How would you explain it do avoid confusions?
Sorry, something went wrong.
There was a problem hiding this comment.
I'm thinking about something like this maybe?
https://github.com/testing-library/testing-library-docs/pull/1231/files#r1148318567
Sorry, something went wrong.
| </body> | ||
| ``` | ||
|
|
||
| you can get the "Login" button by calling |
There was a problem hiding this comment.
| you can get the "Login" button by calling | |
| You can get the "Login" button by calling `getByRole('button', { disabled: true })` and the alert by calling `getByRole('alert', { disabled: false })`. |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
Docs for testing-library/dom-testing-library#1221
Rendered preview