Documentation
¶
Overview ¶
Package slog provides a structured logging system.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Logger ¶
type Logger struct {
// contains filtered or unexported fields
}
Logger represents a structured logger.
type Option ¶
type Option = func(log *Logger)
Option is a function that configures a Logger instance.
func WithContext ¶
WithContext returns an Option that sets the context for the logger.
func WithLogger ¶
WithLogger returns an Option that sets the underlying slog.Logger instance.
func WithMessageKey ¶
WithMessageKey returns an Option that sets the message key for the logger.
Click to show internal directories.
Click to hide internal directories.