Module

x/fresh/server.ts>FreshContext

The next-gen web framework.
Extremely Popular
Latest
interface FreshContext
import { type FreshContext } from "https://dotland.deno.dev/x/fresh@1.7.3/server.ts";

Type Parameters

optional
State = Record<string, unknown>
optional
Data = any
optional
NotFoundData = Data

Properties

optional
localAddr: Deno.NetAddr
remoteAddr: Deno.NetAddr
url: URL
basePath: string
route: string
deprecated
pattern: string
destination: router.DestinationKind
params: Record<string, string>
isPartial: boolean
state: State
data: Data
optional
error: unknown

The error that caused the error page to be loaded.

optional
codeFrame: unknown

Sringified code frame of the error rendering failed (only in development mode)

renderNotFound: (data?: NotFoundData) => Response | Promise<Response>
render: (data?: Data, options?: RenderOptions) => Response | Promise<Response>
Component: ComponentType<unknown>
next: () => Promise<Response>