Whoopie - v0.0.2
    Preparing search index...

    Interface CookieOptions

    Options of a Set-Cookie header or a cookie that can be assigned to Document.cookie.

    interface CookieOptions {
        domain?: string;
        expiresAt?: string | number | Date;
        isHttpOnly?: boolean;
        isPartitioned?: boolean;
        isSecure?: boolean;
        maxAge?: number;
        path?: string;
        sameSite?: "strict" | "lax" | "none";
    }
    Index

    Properties

    domain?: string

    Defines the host to which the cookie will be sent.

    Only the current domain can be set as the value, or a domain of a higher order, unless it is a public suffix. Setting the domain will make the cookie available to it, as well as to all its subdomains.

    If omitted, this attribute defaults to the host of the current document URL, not including subdomains.

    Leading dots in domain names (.example.com) are ignored.

    Multiple host/domain values are not allowed, but if a domain is specified, then subdomains are always included.

    expiresAt?: string | number | Date

    Indicates the maximum lifetime of the cookie as an HTTP-date timestamp. See Date for the required formatting.

    isHttpOnly?: boolean

    Forbids JavaScript from accessing the cookie, for example, through the document.cookie property.

    isPartitioned?: boolean

    Indicates that the cookie should be stored using partitioned storage. Note that if this is set to true, isSecure must also be set to true. See Cookies Having Independent Partitioned State (CHIPS) for more details.

    isSecure?: boolean

    Indicates that the cookie is sent to the server only when a request is made with the https: scheme (except on localhost).

    maxAge?: number

    Indicates the number of seconds until the cookie expires. A zero or negative number will expire the cookie immediately.

    If both expiresAt and maxAge are set, maxAge has precedence.

    path?: string

    Indicates the path that must exist in the requested URL for the browser to send the Cookie header.

    sameSite?: "strict" | "lax" | "none"

    Controls whether or not a cookie is sent with cross-site requests: that is, requests originating from a different site, including the scheme, from the site that set the cookie.