sloger

package
v0.0.0-...-38563ce Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 28, 2025 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	DefaultLogger = slog.Default()
)

Functions

func FromContext

func FromContext(ctx context.Context) *slog.Logger

func SetDefaultLogger

func SetDefaultLogger(l *slog.Logger)

func SetInContext

func SetInContext(ctx context.Context, args ...any) (context.Context, *slog.Logger)

func With

func With(args ...any) *slog.Logger

Types

type ContextKey

type ContextKey string
var LoggerKey ContextKey = "logger"

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL