logging.d.ts
 1  export declare let logLevel: LogLevel;
 2  export declare function setLogLevel(newLogLevel: LogLevel): void;
 3  export declare function increaseVerbosity(): void;
 4  export declare const trace: (fmt: string, ...args: any) => false | void;
 5  export declare const debug: (fmt: string, ...args: any[]) => false | void;
 6  export declare const error: (fmt: string, ...args: any[]) => void;
 7  export declare const warning: (fmt: string, ...args: any[]) => void;
 8  export declare const success: (fmt: string, ...args: any[]) => void;
 9  export declare const highlight: (fmt: string, ...args: any[]) => void;
10  export declare const print: (fmt: string, ...args: any[]) => void;
11  export declare const data: (fmt: string, ...args: any[]) => void;
12  export declare type LoggerFunction = (fmt: string, ...args: any[]) => void;
13  /**
14   * Create a logger output that features a constant prefix string.
15   *
16   * @param prefixString the prefix string to be appended before any log entry.
17   * @param fn   the logger function to be used (typically one of the other functions in this module)
18   *
19   * @returns a new LoggerFunction.
20   */
21  export declare function prefix(prefixString: string, fn: LoggerFunction): LoggerFunction;
22  export declare const enum LogLevel {
23      /** Not verbose at all */
24      DEFAULT = 0,
25      /** Pretty verbose */
26      DEBUG = 1,
27      /** Extremely verbose */
28      TRACE = 2
29  }