API

Class Logger

Logger used throughout the application to allow configuration of the log level required for the messages.

Index
AllLogLevel: 7

All logs

Error: (message: string | any[], limit?: number) => void = ...

Write an error message to the console

ErrorLogLevel: 4

Only error logs

errorsCount: number = 0

Gets a value indicating the number of loading errors

Log: (message: string | any[], limit?: number) => void = ...

Log a message to the console

MessageLimitReached: string = "Too many %TYPE%s (%LIMIT%), no more %TYPE%s will be reported for this message."

Message to display when a message has been logged too many times

MessageLogLevel: 1

Only message logs

NoneLogLevel: 0

No log

OnNewCacheEntry: (entry: string) => void

Callback called when a new log is added

Warn: (message: string | any[], limit?: number) => void = ...

Write a warning message to the console

WarningLogLevel: 2

Only warning logs

  • set LogLevels(level: number): void

    Sets the current log level. This property is a bit field, allowing you to combine different levels (MessageLogLevel / WarningLogLevel / ErrorLogLevel). Use NoneLogLevel to disable logging and AllLogLevel for a quick way to enable all levels.

    Parameters

    • level: number

    Returns void