diff --git a/docs/queries/about.mdx b/docs/queries/about.mdx index 0d1a6fe5c..0747be78f 100644 --- a/docs/queries/about.mdx +++ b/docs/queries/about.mdx @@ -170,9 +170,11 @@ const inputNode1 = screen.getByLabelText('Username') const container = document.querySelector('#app') const inputNode2 = getByLabelText(container, 'Username') ``` + ### `queryOptions` -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). +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). ### `screen` @@ -240,7 +242,8 @@ cy.findByLabelText('Example').should('exist') ## `TextMatch` Most of the query APIs take a `TextMatch` as an argument, which means the -argument can be either a _string_, _regex_, or a _function_ of signature `(content?: string, element?: Element | null) => boolean` which returns `true` +argument can be either a _string_, _regex_, or a _function_ of signature +`(content?: string, element?: Element | null) => boolean` which returns `true` for a match and `false` for a mismatch. ### TextMatch Examples @@ -370,7 +373,8 @@ screen.debug(screen.getAllByText('multi-test')) ### `screen.logTestingPlaygroundURL()` For debugging using [testing-playground](https://testing-playground.com), screen -exposes this convenient method which logs a URL that can be opened in a browser. +exposes this convenient method which logs and returns a URL that can be opened in +a browser. ```javascript import {screen} from '@testing-library/dom'