UNPKG

dewy

Version:

Dewy(dǝw-y) is a minimalist HTTP server framework with a small codebase, utilizing built-in URLPattern for efficient routing.

18 lines (17 loc) 511 B
export class ServerError extends Error { constructor(messageOrError, init) { super(typeof messageOrError === "string" ? messageOrError : messageOrError.message); Object.defineProperty(this, "init", { enumerable: true, configurable: true, writable: true, value: init }); if (messageOrError instanceof Error) { this.cause = messageOrError; } this.name = "ServerError"; } }