A basic logger which handles filtering by level.

With the default options it will write to console.error and it will use the formatting provided by console.error. If the destination is overwritten, then it will use an included formatter similar to util.format.

If a formatter is available, then that should be overridden as well for performance.

Implements

  • LDLogger

Constructors

Methods

Constructors

  • Parameters

    • options: BasicLoggerOptions

    Returns BasicLogger

Methods

  • The debug logger.

    Parameters

    • ...args: any[]

      A sequence of any JavaScript values.

    Returns void

  • The error logger.

    Parameters

    • ...args: any[]

      A sequence of any JavaScript values.

    Returns void

  • The info logger.

    Parameters

    • ...args: any[]

      A sequence of any JavaScript values.

    Returns void

  • The warning logger.

    Parameters

    • ...args: any[]

      A sequence of any JavaScript values.

    Returns void

  • This should only be used as a default fallback and not as a convenient solution. In most cases you should construct a new instance with the appropriate options for your specific needs.

    Returns BasicLogger