Flatiron's logging library Winston is quite useful, but I can not figure how to assign names to loggers. I am expecting an output similar to other logging libraries, for instance:
[<date>] [<log level>] <logger name> - <the message>
Is it possible to configure Winston in such a way?
Thank you.
https://github.com/mcclellanmj/SimplyLog goes on the premise of being able to code your own appenders with custom output easily and is centered around named loggers.
When creating a logging transport, you can provide a
label
parameter which will be added to the log output between the log level and the log message. For example:This will result in the following output:
You can name loggers; however, there doesn't appear to be a way to add the logger name to the output.
But I would use this too, if it was available. There is an open pull request that would allow this by adding a 'name' to the output string, so hopefully that comes through.