Skip to content

currentURL()

Returns window’s current URL.

await openBrowser();
await goto("www.google.com");
await currentURL(); # returns "https://www.google.com/?gws_rd=ssl"

This API does not have any parameters.

TypeDescription
Promise<string>The URL of the current window.