UNPKG

526 BTypeScriptView Raw
1export declare const addCustomErrorDeserializer: (name: string, deserializer: (obj: any) => any) => void;
2declare type CustomErrorFunc = (message?: string, fields?: {
3 [key: string]: any;
4}) => void;
5export declare const createCustomErrorClass: (name: string) => CustomErrorFunc;
6export declare const deserializeError: (object: any) => Error;
7export declare const serializeError: (value: any) => undefined | To | string;
8interface To {
9 name?: string;
10 message?: string;
11 stack?: string;
12}
13export {};