Interface LightLogger

Many libraries use a logger interface to log information about the processing. This logger is expected to be compatible not only with the one from the pino library but also with the default console. This means that the library can output logs by default to the console and the user can replace it with a custom logger that implements this interface.

interface LightLogger {
    debug(obj, message): void;
    debug(message): void;
    debug(error): void;
    debug(value, message?): void;
    error(obj, message): void;
    error(message): void;
    error(error): void;
    error(value, message?): void;
    info(obj, message): void;
    info(message): void;
    info(error): void;
    info(value, message?): void;
    trace(obj, message): void;
    trace(message): void;
    trace(error): void;
    trace(value, message?): void;
    warn(obj, message): void;
    warn(message): void;
    warn(error): void;
    warn(value, message?): void;
}

Hierarchy

Methods

  • Parameters

    • obj: Record<string, unknown>
    • message: string

    Returns void

  • Parameters

    • message: string

    Returns void

  • Parameters

    • error: Error

    Returns void

  • Parameters

    • value: unknown
    • Optional message: string

    Returns void

  • Parameters

    • obj: Record<string, unknown>
    • message: string

    Returns void

  • Parameters

    • message: string

    Returns void

  • Parameters

    • error: Error

    Returns void

  • Parameters

    • value: unknown
    • Optional message: string

    Returns void

  • Parameters

    • obj: Record<string, unknown>
    • message: string

    Returns void

  • Parameters

    • message: string

    Returns void

  • Parameters

    • error: Error

    Returns void

  • Parameters

    • value: unknown
    • Optional message: string

    Returns void

  • Parameters

    • obj: Record<string, unknown>
    • message: string

    Returns void

  • Parameters

    • message: string

    Returns void

  • Parameters

    • error: Error

    Returns void

  • Parameters

    • value: unknown
    • Optional message: string

    Returns void

  • Parameters

    • obj: Record<string, unknown>
    • message: string

    Returns void

  • Parameters

    • message: string

    Returns void

  • Parameters

    • error: Error

    Returns void

  • Parameters

    • value: unknown
    • Optional message: string

    Returns void