NextCookies
The subset of Next.js’s ReadonlyRequestCookies / ResponseCookies API
this adapter depends on. Kept structural to avoid importing next at
runtime from this framework-agnostic shim.
Methods
Section titled “Methods”delete()
Section titled “delete()”delete(
name):void
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
name |
string |
Returns
Section titled “Returns”void
get(
name): {value?:string; } |undefined
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
name |
string |
Returns
Section titled “Returns”{ value?: string; } | undefined
set(
name,value,opts?):void
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
name |
string |
value |
string |
opts? |
{ expires?: Date; httpOnly?: boolean; maxAge?: number; path?: string; sameSite?: "lax" | "strict" | "none"; secure?: boolean; } |
opts.expires? |
Date |
opts.httpOnly? |
boolean |
opts.maxAge? |
number |
opts.path? |
string |
opts.sameSite? |
"lax" | "strict" | "none" |
opts.secure? |
boolean |
Returns
Section titled “Returns”void