UNPKG

885 BTypeScriptView Raw
1export interface IDebug {
2 (namespace: string): IDebugger;
3 coerce: (val: any) => any;
4 disable: () => string;
5 enable: (namespaces: string) => void;
6 enabled: (namespaces: string) => boolean;
7 log: (...args: any[]) => any;
8 names: RegExp[];
9 skips: RegExp[];
10 formatters: DebugFormatters;
11}
12export interface DebugFormatters {
13 [formatter: string]: (v: any) => string;
14}
15export interface IDebugger {
16 (...args: any[]): void;
17 debug: (...args: any[]) => void;
18 info: (...args: any[]) => void;
19 warn: (...args: any[]) => void;
20 error: (...args: any[]) => void;
21 color: string;
22 enabled: boolean;
23 log: (...args: any[]) => any;
24 namespace: string;
25 destroy: () => boolean;
26}
27export declare enum DebugLogLevel {
28 debug = "debug",
29 info = "info",
30 warn = "warn",
31 error = "error"
32}
33export declare const Debug: IDebug;