Skip to content

Commit 3ec0675

Browse files
Lirlev48MatanBobitimdeschryver
authored
docs: modify logTestingPlaygroundURL documentation (#1105)
* doc logTestingPlaygroundURL * docs: update text for logTestingPlaygroundURL Co-authored-by: Tim Deschryver <[email protected]> Co-authored-by: lironlevy <xvsciuvmcy27kruon22t3wvv2kfiqoguhmnnkebe6y5kmbl7vuzq> Co-authored-by: Matan Borenkraout <[email protected]> Co-authored-by: Tim Deschryver <[email protected]>
1 parent e2dffa9 commit 3ec0675

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

docs/queries/about.mdx

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -170,9 +170,11 @@ const inputNode1 = screen.getByLabelText('Username')
170170
const container = document.querySelector('#app')
171171
const inputNode2 = getByLabelText(container, 'Username')
172172
```
173+
173174
### `queryOptions`
174175

175-
You can pass a `queryOptions` object with the query type. See the docs for each query type to see available options, e.g. [byRole API](queries/byrole.mdx#api).
176+
You can pass a `queryOptions` object with the query type. See the docs for each
177+
query type to see available options, e.g. [byRole API](queries/byrole.mdx#api).
176178

177179
### `screen`
178180

@@ -240,7 +242,8 @@ cy.findByLabelText('Example').should('exist')
240242
## `TextMatch`
241243

242244
Most of the query APIs take a `TextMatch` as an argument, which means the
243-
argument can be either a _string_, _regex_, or a _function_ of signature `(content?: string, element?: Element | null) => boolean` which returns `true`
245+
argument can be either a _string_, _regex_, or a _function_ of signature
246+
`(content?: string, element?: Element | null) => boolean` which returns `true`
244247
for a match and `false` for a mismatch.
245248

246249
### TextMatch Examples
@@ -370,7 +373,8 @@ screen.debug(screen.getAllByText('multi-test'))
370373
### `screen.logTestingPlaygroundURL()`
371374

372375
For debugging using [testing-playground](https://testing-playground.com), screen
373-
exposes this convenient method which logs a URL that can be opened in a browser.
376+
exposes this convenient method which logs and returns a URL that can be opened in
377+
a browser.
374378

375379
```javascript
376380
import {screen} from '@testing-library/dom'

0 commit comments

Comments
 (0)