Closed Altroo closed 1 year ago
Found it :
// next-logger.config.js
const pino = require('pino');
const logger = (defaultConfig) =>
pino({
...defaultConfig,
formatters: {
level: (label) => {
return { level: label };
},
},
timestamp: pino.stdTimeFunctions.isoTime,
}, pino.destination(`${__dirname}/logs/debug.log`));
module.exports = {
logger,
};
Hello,
As the title say i would like for example to log two files, debug.log for debug logs & error.log to catch errors, i couldn't find something related to this in the library, but perhaps i'm missing something, or override some config ?
Thank's in advance.