fastify / one-line-logger

Helps you format fastify's log into a nice one line message
MIT License
32 stars 7 forks source link

Support CustomLevels #7

Closed Uzlopak closed 1 year ago

Uzlopak commented 1 year ago

Prerequisites

🚀 Feature Proposal

One-Line-Logger should support CustomLogLevels

Motivation

While refactoring I realized, that only the default loglevels are supported. When somebody uses a custom log level i assume, that you get "undefined" for the log level. I assume we can passthrough the pino pretty option customLevels, parse it and merge it with the default values.

Example

No response

bortolottidev commented 1 year ago

Hey! Just pushed a PR https://github.com/fastify/one-line-logger/pull/18

Dont know why is it not automagically linked on this issue

Fdawgs commented 1 year ago

Dont know why is it not automagically linked on this issue

You need to write things like closes #7 or fixes #7 for it to link. I've linked it anyway. 😄