Skip to main content

Interface: LoggerOptions

@sapphire/plugin-logger.LoggerOptions

The logger options.

since 1.0.0

Properties

defaultFormat

Optional defaultFormat: LoggerLevelOptions

The default options used to fill all the possible values for LoggerOptions.format.

since 1.0.0

default options.format.none ?? {}

Defined in

projects/plugins/packages/logger/src/lib/Logger.ts:127


depth

Optional depth: number

The inspect depth when logging objects.

since 1.0.0

default 0

Defined in

projects/plugins/packages/logger/src/lib/Logger.ts:156


format

Optional format: LoggerFormatOptions

The options for each log level. LogLevel.None serves to set the default for all keys, where only {@link LoggerTimestampOptions.timestamp} and {@link LoggerLevelOptions.prefix} would be overridden.

since 1.0.0

default {}

Defined in

projects/plugins/packages/logger/src/lib/Logger.ts:135


join

Optional join: string

The string that joins different messages.

since 1.0.0

default ' '

Defined in

projects/plugins/packages/logger/src/lib/Logger.ts:149


level

Optional level: LogLevel

The minimum log level.

since 1.0.0

default LogLevel.Info

Defined in

projects/plugins/packages/logger/src/lib/Logger.ts:142


stderr

Optional stderr: WriteStream

A WriteStream for the error logs.

since 1.0.0

default process.stderr

Defined in

projects/plugins/packages/logger/src/lib/Logger.ts:120


stdout

Optional stdout: WriteStream

The WriteStream for the output logs.

since 1.0.0

default process.stdout

Defined in

projects/plugins/packages/logger/src/lib/Logger.ts:113