Skip to main content
Module

x/enzastdlib/vendor/@deno-std-http.ts>ServeInit

enzastdlib is a set of TypeScript modules that follow a common design API philosophy aiming at sane defaults and ease-of-use targeting the Deno TypeScript runtime.
Latest
interface ServeInit
implements Partial<Deno.ListenOptions>
import { type ServeInit } from "https://deno.land/x/enzastdlib@v0.0.4/vendor/@deno-std-http.ts";

Additional serve options.

Properties

optional
signal: AbortSignal

An AbortSignal to close the server and all connections.

optional
onError: (error: unknown) => Response | Promise<Response>

The handler to invoke when route handlers throw an error.

optional
onListen: (params: { hostname: string; port: number; }) => void

The callback which is called when the server started listening