Skip to content

NuxtCookieEvent

Minimal interface over an h3 H3Event (or any cookie bag) that this adapter needs. Kept structural so it works against Nuxt’s event without importing h3 at runtime.

deleteCookie(name, opts?): void

Delete a cookie.

Parameter Type
name string
opts? { path?: string; }
opts.path? string

void


getCookie(name): string | undefined

Read a cookie value.

Parameter Type
name string

string | undefined


setCookie(name, value, opts?): void

Set a cookie with options.

Parameter Type
name string
value string
opts? { httpOnly?: boolean; maxAge?: number; path?: string; sameSite?: "lax" | "strict" | "none"; secure?: boolean; }
opts.httpOnly? boolean
opts.maxAge? number
opts.path? string
opts.sameSite? "lax" | "strict" | "none"
opts.secure? boolean

void