CookieStore

The CookieStore interface of the Cookie Store API provides methods for getting and setting cookies asynchronously from either a page or a service worker. Available only in secure contexts.

MDN Reference

Functions

Link copied to clipboard
suspend fun delete(name: String)
suspend fun delete(options: CookieStoreDeleteOptions)
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
suspend fun get(name: String): CookieListItem?
suspend fun get(options: CookieStoreGetOptions = definedExternally): CookieListItem?
Link copied to clipboard
suspend fun getAll(name: String): CookieList
suspend fun getAll(options: CookieStoreGetOptions = definedExternally): CookieList
Link copied to clipboard
Link copied to clipboard
fun getAsync(options: CookieStoreGetOptions = definedExternally): Promise<CookieListItem?>
Link copied to clipboard
suspend fun set(options: CookieInit)

suspend fun set(name: String, value: String)
Link copied to clipboard
fun setAsync(name: String, value: String): Promise<Void>
Link copied to clipboard