Skip to main content
Module

x/cav/router.ts>router

A server framework for Deno
Go to Latest
function router
import { router } from "https://deno.land/x/cav@0.2.3/router.ts";

Constructs a new Router handler using the provided routes. The route properties are also available on the returned Router function.

Parameters

routes: S & [K in keyof S]: (K extends (
| `${string}//${string}`
| `/${string}`
| `${string}/`
| `../${string}`
| `./${string}`
| `${string}/..`
| `${string}/.`
| `${string}/../${string}`
| `${string}/./${string}`
| `${string}*/${string}`
| `${string}/*${string}`
) ? never : S[K])