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
6 changes: 3 additions & 3 deletions docs/queries/bylabeltext.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ The example below will find the input node for the following DOM structures:
// aria-label attributes
// Take care because this is not a label that users can see on the page,
// so the purpose of your input must be obvious to visual users.
<input aria-label="username" />
<input aria-label="Username" />
```

<Tabs defaultValue="native" values={[ { label: 'Native', value: 'native', }, {
Expand All @@ -71,14 +71,14 @@ import { render, screen } from '@testing-library/react'

render(<Login />)

const inputNode = screen.getByLabelText('username')
const inputNode = screen.getByLabelText('Username')
```

</TabItem>
<TabItem value="cypress">

```js
cy.findByLabelText('username').should('exist')
cy.findByLabelText('Username').should('exist')
```

</TabItem>
Expand Down