For AI agents: a documentation index is available at /llms.txt
Skip to main content

waitForNavigation

Waits for a future navigation event. If a click triggers the navigation, use click with waitUntil so the wait starts before the click.

**Usage Example:**

mutation ClickAndWait {
click(selector: "a.next", waitUntil: load) {
navigation { status }
}
}

**Field Definition:**

waitForNavigation(
timeout: Float
waitUntil: WaitUntilGoto = load
): HTTPResponse

Arguments​

waitForNavigation.timeout ● Float scalar​

The maximum amount of time, in milliseconds, to wait for the page to load, overriding any defaults. Default timeout is 30 seconds, or 30000.

waitForNavigation.waitUntil ● WaitUntilGoto enum​

When to consider the page fully-loaded and proceed with further execution

Type​

HTTPResponse object​

Response returned after a navigation event

Was this page helpful?