logger

package
v0.11.2 Latest Latest
Warning

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

Go to latest
Published: Jul 10, 2026 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewLogger

func NewLogger(cfg Config) *slog.Logger

NewLogger creates a new slog logger with configurable log level and format

func ParseLevel

func ParseLevel(level string) slog.Level

ParseLevel converts a log level string to slog.Level

Types

type Config

type Config struct {
	Level  string // "debug", "info", "warn", "error"
	Format string // "json" (default) or "text"
}

Config holds logger configuration

Jump to

Keyboard shortcuts

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