Show HN: LogLayer – Unified logger that routes logs to various logging libraries
As a longtime TypeScript/Node.js developer, I've often faced challenges with logging—choosing, using, and maintaining the right logger for various projects. While most loggers offer the usual methods like "info", "warn", and "error", they vary significantly in how they handle structured metadata or Error objects. This can lead to ad-hoc solutions, like serializing errors or writing custom pipelines, just to get logs formatted correctly. I built LogLayer to address these pain points by introducing a fluid, expressive API. With methods like "withMetadata" and "withError", LogLayer separates object injection from the log message itself, making your logging code both cleaner and more maintainable. Logs are processed through a LogLayer Transport, which acts as an adapter for your preferred logging library. This design offers several key advantages: - Multi-Transport Support: Send logs to multiple destinations (e.g., DataDog and New
DeepCamp AI