Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func WithLogrus ¶
func WithLogrus(l *log.Logger) func(*LogrusMiddleware)
func WithSlog ¶ added in v0.1.2
func WithSlog(l *slog.Logger) func(*SlogMiddleware)
Types ¶
type LogrusMiddleware ¶
type LogrusMiddleware struct {
// contains filtered or unexported fields
}
func NewLogrus ¶
func NewLogrus(opts ...LogrusOptionFunc) *LogrusMiddleware
func (*LogrusMiddleware) Middleware ¶
func (m *LogrusMiddleware) Middleware(next http.Handler) http.Handler
type LogrusOptionFunc ¶
type LogrusOptionFunc func(*LogrusMiddleware)
type SlogMiddleware ¶ added in v0.1.2
type SlogMiddleware struct {
// contains filtered or unexported fields
}
func NewSlog ¶ added in v0.1.2
func NewSlog(opts ...SlogOptionFunc) *SlogMiddleware
func (*SlogMiddleware) Middleware ¶ added in v0.1.2
func (m *SlogMiddleware) Middleware(next http.Handler) http.Handler
type SlogOptionFunc ¶ added in v0.1.2
type SlogOptionFunc func(*SlogMiddleware)
Click to show internal directories.
Click to hide internal directories.