UNPKG

@zodash/throw

Version:
9 lines (8 loc) 330 B
import { ApiError } from '@zodash/error'; export declare type Message = string | { code: string; message: string; }; export declare function createError(status: number, message: Message): ApiError; export declare function throwError(status: number, message: Message): void; export declare const _throw: typeof throwError;