Closed UndefinedBehaviour closed 1 year ago
Issue
import { pinoHttp } from 'pino-http'; const httpLogger = pinoHttp({ customLevels: { log: 20, }, }); const logger = httpLogger.logger; function f(level: 'warn' | 'info' | 'log', message: string): void { logger[level](message); }
This code is correct but currently throws a ts(7053) : Element implicitly has an 'any' type because TS can't see the custom level added in the configuration.
ts(7053) : Element implicitly has an 'any' type
Test added!
Issue
This code is correct but currently throws a
ts(7053) : Element implicitly has an 'any' type
because TS can't see the custom level added in the configuration.