x/oak/middleware/serve.ts

A middleware framework for handling HTTP with Deno, Node, Bun and Cloudflare Workers 🐿️ 🦕
Very Popular
Latest
class RouteContext
extends ServeContext<S>
import { RouteContext } from "https://dotland-vbqsvsrpfncg.deno-staging.dev/x/oak@v17.1.3/middleware/serve.ts?p=prototype.%5BSymbol.for%28%22Deno.customInspect%22%29%5D&s=RouteContext";

The context associated with serve middleware requests on a router.

Constructors

new
RouteContext(context: RouterContext<R, P, S>)
[src]

Type Parameters

R extends string[src]
optional
P extends RouteParams<R> = RouteParams<R>
[src]
optional
S extends State = State
[src]

Properties

readonly
captures: string[]
[src]

When matching the route, an array of the capturing groups from the regular expression.

readonly
matched: Layer<R, P, S>[] | undefined
[src]

The routes that were matched for this request.

readonly
params: P
[src]

Any parameters parsed from the route when matched.

readonly
routeName: string | undefined
[src]

If the matched route has a name, the matched route name is provided here.

readonly
router: Router<S>
[src]

A reference to the router instance.

readonly
routerPath: string | undefined
[src]

Overrides the matched path for future route middleware, when a routerPath option is not defined on the Router options.

Methods

[Symbol.for("Deno.customInspect")](inspect: (value: unknown) => string): string[src]
[Symbol.for("nodejs.util.inspect.custom")](
depth: number,
options: any,
inspect: (value: unknown, options?: unknown) => string,
): any
[src]