Version: 4.3

Class: Logger

Hierarchy

  • Logger

Constructors

constructor

+ new Logger(logger: (message: string) => void, debugMode?: boolean | LoggerNamespace[]): Logger

Defined in packages/core/src/utils/Logger.ts:3

Parameters:

NameTypeDefault value
logger(message: string) => void-
debugModeboolean | LoggerNamespace[]false

Returns: Logger

Properties

debugMode

debugMode: boolean | LoggerNamespace[]

Defined in packages/core/src/utils/Logger.ts:6


logger

Private Readonly logger: (message: string) => void

Defined in packages/core/src/utils/Logger.ts:5

Methods

isEnabled

isEnabled(namespace: LoggerNamespace): boolean

Defined in packages/core/src/utils/Logger.ts:28

Parameters:

NameType
namespaceLoggerNamespace

Returns: boolean


log

log(namespace: LoggerNamespace, message: string): void

Defined in packages/core/src/utils/Logger.ts:11

Logs a message inside given namespace.

Parameters:

NameType
namespaceLoggerNamespace
messagestring

Returns: void


setDebugMode

setDebugMode(debugMode: boolean | LoggerNamespace[]): void

Defined in packages/core/src/utils/Logger.ts:24

Sets active namespaces. Pass true to enable all logging.

Parameters:

NameType
debugModeboolean | LoggerNamespace[]

Returns: void

Last updated on by Martin Adámek