Closed aaronovz1 closed 3 years ago
Would you like to send a PR to correct the docs?
It's not just the docs that are wrong. See the error at the bottom. How do I fix that so it's compatible with latest pino? pino() doesn't return an object where pipe's can be set it seems.
Any suggestions on how to fix the pipe error?
Sorry. I'm not a pino-tee
user and I don't have time to investigate. But I'm willing to bet it's just not compatible with pino-pretty
. @mcollina might know better.
I don’t know either :(
I am facing the same problem as @aaronovz1. Any helps would be appreciated.
const pretty = pino({ prettyPrint: { colorize: true }, }); pretty.pipe(process.stdout); logThrough.pipe(pretty);
Hi, I am able to make it work with my nodejs express project.
const logger = pino({
level: process.env.LOG_LEVEL || "info",
prettyPrint: true,
});
const expressLogger = expressPino({ logger });
I have created a repository with an example of my codes. Feel free to check out on the link below:
Hi guys, I have found out, the reason is the newest version of pino pretty is not support like that let's try, and it is working for me
yarn add pino-pretty@5.1.2
Using the example from the homepage - this does not work anymore on latest version of Pino.
Changing it to
Solves that problem but then this error happens:
TypeError: pretty.pipe is not a function