Skip to main content

HttpCookies

A CookieStore that also knows how to write its buffered mutations onto a response's headers. Build one per request; after driving a ServerAuthSession with it, call HttpCookies.applyTo on the response you return.

Extends​

Properties​

PropertyTypeDescriptionInherited from
applyTo(headers) => voidAppend a Set-Cookie header for every write/delete made on this store.-
delete(name, options?) => void | Promise<void>Delete a cookie. Must be given the same path/domain the cookie was written with, or the deletion won't match it.CookieStore.delete
get(name) => string | Promise<string | undefined> | undefinedRead a cookie value.CookieStore.get
set(name, value, options?) => void | Promise<void>Write a cookie.CookieStore.set