Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/fresh_session/src/stores/deno_kv_store.ts>getDenoKvSession

Dead simple cookie-based session for Deno Fresh.
Latest
function getDenoKvSession
import { getDenoKvSession } from "https://deno.land/x/fresh_session@beta-0.3.1/src/stores/deno_kv_store.ts";

Type Parameters

T extends string
F extends string

Parameters

req: Request
cookieName: string
baseKeyPath: string[]
keyPrefix: string
client: Deno.Kv

Returns

Promise<{ session: Session<T, F>; sessionCookieSetter: { (res: Response, cookieOptions: RequiredCookieOptions): Response | Promise<Response>; }; }>