:: features
Why Logger?
Structured Output
JSON-structured logs with context, timestamps, and correlation IDs out of the box.
Multiple Transports
Console, file, HTTP, and custom transports. Route logs to any destination.
Log Levels
Trace, debug, info, warn, error, fatal. Filter by level per transport.
Context Propagation
Attach request IDs, user context, and trace spans to every log entry automatically.
Port-Based
Logger is a port. Swap between Pino, Winston, or a test logger with zero code changes.
Child Loggers
Create scoped child loggers that inherit parent context and add their own.
:: ecosystem
Part of the HexDI Stack
Logger integrates seamlessly with the HexDI dependency injection ecosystem. Use it standalone or compose it with other libraries.
Explore HexDI