Skip to content

ElectronCookiesSetDetails

Unofficial

Details used to set a cookie on an Electron session.

Import:

import type { ElectronCookiesSetDetails } from '@obsidian-typings/obsidian-public-latest';

Signature:

export interface ElectronCookiesSetDetails

Properties

PropertyTypeDescription
domain?stringThe domain of the cookie; normalized with a preceding dot so that it is also valid for subdomains. Empty by default if omitted.
expirationDate?numberThe expiration date of the cookie as the number of seconds since the UNIX epoch. If omitted then the cookie becomes a session cookie and will not be retained between sessions.
httpOnly?booleanWhether the cookie should be marked as HTTP only.
name?stringThe name of the cookie. Empty by default if omitted.
path?stringThe path of the cookie. Empty by default if omitted.
sameSite?'lax' | 'no_restriction' | 'strict' | 'unspecified'The Same Site policy to apply to this cookie.
secure?booleanWhether the cookie should be marked as Secure.
urlstringThe URL to associate the cookie with. The promise will be rejected if the URL is invalid.
value?stringThe value of the cookie. Empty by default if omitted.