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

x/deno_nest/modules/hono/deps.ts>HonoContext

Refer to nestjs to realize some common functions for Deno, support hono and oak
Go to Latest
class HonoContext
import { HonoContext } from "https://deno.land/x/deno_nest@v3.6.1/modules/hono/deps.ts";

Constructors

new
HonoContext(req: HonoRequest<P, I["out"]>, options?: ContextOptions<E>)

Type Parameters

optional
E extends Env = any
optional
P extends string = any
optional
I extends Input = { }

Properties

private
_exCtx: FetchEventLike | ExecutionContext | undefined
private
_h: Headers | undefined
private
_init: boolean
private
_pH: Record<string, string> | undefined
private
_renderer: Renderer
private
_res: Response | undefined
private
_status: StatusCode
private
_var: E["Variables"]
private
notFoundHandler: NotFoundHandler<E>
body: BodyRespond
env: E["Bindings"]
error: Error | undefined
readonly
event: FetchEventLike
readonly
executionCtx: ExecutionContext
finalized: boolean
get: Get<E>
header: (
name: string,
value: string | undefined,
options?: { append?: boolean; },
) => void
html: HTMLRespond
json: JSONRespond
jsonT: JSONTRespond
newResponse: NewResponse
notFound: () => Response | Promise<Response>
redirect: (location: string, status?: StatusCode) => Response
render: Renderer
req: HonoRequest<P, I["out"]>
deprecated
readonly
runtime: Runtime
set: Set<E>
setRenderer: (renderer: Renderer) => unknown
status: (status: StatusCode) => void
stream: (
cb: (stream: StreamingApi) => Promise<void>,
arg?: StatusCode | ResponseInit,
headers?: HeaderRecord,
) => Response
streamText: (
cb: (stream: StreamingApi) => Promise<void>,
arg?: StatusCode | ResponseInit,
headers?: HeaderRecord,
) => Response
text: TextRespond
readonly
var: Readonly<E["Variables"]>