Interface Debug

interface Debug {
    formatters: Formatters;
    humanize: {
        (value, options?): number;
        (value, options?): string;
    };
    inspectOpts?: {
        colors?: null | number | boolean;
        depth?: null | number | boolean;
        hideDate?: null | number | boolean;
        showHidden?: null | number | boolean;
    };
    names: RegExp[];
    skips: RegExp[];
    coerce(val): any;
    disable(...args): string;
    enable(namespaces): void;
    enabled(namespaces): boolean;
    formatArgs(this, args): void;
    log(...args): any;
    selectColor(namespace): string | number;
    (namespace): Debugger;
}

Properties

formatters: Formatters
humanize: {
    (value, options?): number;
    (value, options?): string;
}

Type declaration

    • (value, options?): number
    • Parse or format the given val.

      Parameters

      • value: StringValue

        The string or number to convert

      • Optional options: Options

        Options for the conversion

      Returns number

      Throws

      Error if value is not a non-empty string or a number

    • (value, options?): string
    • Parameters

      • value: number
      • Optional options: Options

      Returns string

inspectOpts?: {
    colors?: null | number | boolean;
    depth?: null | number | boolean;
    hideDate?: null | number | boolean;
    showHidden?: null | number | boolean;
}

Type declaration

  • Optional colors?: null | number | boolean
  • Optional depth?: null | number | boolean
  • Optional hideDate?: null | number | boolean
  • Optional showHidden?: null | number | boolean
names: RegExp[]
skips: RegExp[]

Methods

  • Parameters

    • Rest ...args: string[]

    Returns string

  • Parameters

    • namespaces: string | boolean

    Returns void

  • Parameters

    • namespaces: string

    Returns boolean

  • Parameters

    • Rest ...args: any[]

    Returns any

  • Parameters

    • namespace: string

    Returns string | number