logging

package
v0.4.8 Latest Latest
Warning

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

Go to latest
Published: Jan 3, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Overview

Package logging provides helper functions to use a structured logger.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewJsonLogger

func NewJsonLogger() *slog.Logger

NewJsonLogger creates a new structured logger in JSON format.

func WithLogging added in v0.1.93

func WithLogging(logger *slog.Logger, next http.HandlerFunc) http.HandlerFunc

WithLogging logs the request with method, path and duration.

Types

This section is empty.

Jump to

Keyboard shortcuts

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