JS API Reference

Module: utils/logger/defaultLogger

Table of contents

Functions

Functions

defaultLogger

defaultLogger(namespace): Object

Creates a logger that uses the debug library. This logger is used by default by all entities in the SDK. If the namespace is not prefixed with golem-js:, it will be prefixed automatically.

Parameters

NameType
namespacestring

Returns

Object

NameType
child(childNamespace: string) => { child: (childNamespace: string) => ...; info: (msg: string) => void; error: (msg: string) => void; warn: (msg: string) => void; debug: (msg: string) => void; log: (msg: string, ctx?: Error | Record<...> | undefined) => void; }
info(msg: string) => void
error(msg: string) => void
warn(msg: string) => void
debug(msg: string) => void
log(msg: string, ctx?: Error | Record<string, unknown>) => void

Defined in

src/utils/logger/defaultLogger.ts:7