Browser.setCookie() method
Sets cookies in the default BrowserContext.
Signature
class Browser {
setCookie(...cookies: Cookie[]): Promise<void>;
}
Parameters
Parameter | Type | Description |
---|---|---|
cookies | Cookie[] |
Returns:
Promise<void>
Remarks
Shortcut for browser.defaultBrowserContext().setCookie().