Slogr provides an implementation of logr interfaces backed by slog.
slogLogger := slog.New(slog.NewTextHandler(os.Stdout, &slog.HandlerOptions{}))
var log logr.Logger = slogr.New(slogLogger)
log.Info("Access granted.", "user", "john.doe" )
An inplementation of logr.Logger interfaces backed by slog
Slogr provides an implementation of logr interfaces backed by slog.
slogLogger := slog.New(slog.NewTextHandler(os.Stdout, &slog.HandlerOptions{}))
var log logr.Logger = slogr.New(slogLogger)
log.Info("Access granted.", "user", "john.doe" )
An inplementation of logr.Logger interfaces backed by slog
Apache License 2.0