[READ-ONLY] Mirror of https://github.com/FoxxMD/logging. A typed, opinionated, batteries-included, Pino-based logging solution for backend TS/JS projects foxxmd.github.io/logging
child-logger logging logging-library nodejs pinojs typescript-library
0

Configure Feed

Select the types of activity you want to include in your feed.

fix: Add custom levels to multistream to fix non-output

Without custom levels added streams would not output if log level was custom (verbose)

FoxxMD (Sep 3, 2025, 3:32 PM UTC) 1659a6d8 71847df3

+2 -2
+2 -2
src/loggers.ts
··· 9 9 LogOptions 10 10 } from "./types.js"; 11 11 import {buildDestinationFile, buildDestinationRollingFile, buildDestinationStdout} from "./destinations.js"; 12 - import {pino} from "pino"; 12 + import {pino, levels} from "pino"; 13 13 14 14 /** 15 15 * Builds a Logger object for use in your application ··· 42 42 customLevels: CUSTOM_LEVELS, 43 43 useOnlyCustomLevels: false, 44 44 ...extras 45 - }, pino.multistream(streams)) as Logger; 45 + }, pino.multistream(streams, {levels: {...levels.values, ...CUSTOM_LEVELS}})) as Logger; 46 46 plogger.labels = []; 47 47 48 48 plogger.addLabel = function (value) {