Skip to main content
Module

x/danet/mod.ts>DanetRouter

The most mature backend framework for Deno
Go to Latest
class DanetRouter
Re-export
import { DanetRouter } from "https://deno.land/x/danet@2.0.3-alpha/mod.ts";

Constructors

new
DanetRouter(
injector: Injector,
guardExecutor?: GuardExecutor,
filterExecutor?: FilterExecutor,
viewRenderer?: Renderer,
middlewareExecutor?: MiddlewareExecutor,
)

Properties

private
logger: Logger
methodsMap: Map
optional
prefix: string
router: Router

Methods

private
registerController(Controller: Constructor)
private
resolveMethodParam(
ControllerMethod: (...args: any[]) => unknown,
context: HttpContext,
)
private
sendResponse(
response: string | Record<string, unknown>,
ControllerMethod: Callback,
context: HttpContext,
)
createRoute(
handlerName: string | hookName,
Controller: Constructor,
basePath: string,
)
handleRoute(Controller: ControllerConstructor, ControllerMethod: Callback)
setPrefix(prefix: string)