Appearance
Function: XPathLabel()
ts
function XPathLabel(label: string, element?: string): string;Defined in: src/wait/waiters/waitForText.ts:13
Build an XPath expression that matches an element by its text content.
Parameters
| Parameter | Type | Default value | Description |
|---|---|---|---|
label | string | undefined | The text to match. |
element | string | '*' | The element tag to search. Defaults to *. |
Returns
string
An XPath string that selects the element containing the label.