UNPKG

@log4js2/core

Version:

log4js2 is a fast and lightweight logging library that enables logging flexibility within JavaScript/TypeScript applications, similar to Apache's [Log4j2 library](https://logging.apache.org/log4j/2.x/). It can also serve as a drop-in replacement for log4

19 lines (18 loc) 568 B
import ILoggerConfiguration from '../config/logger.config'; import { Logger } from './logger'; /** * The name of the main logger. We use this in case no logger is specified * @const */ export declare const MAIN_LOGGER = "main"; export declare const addLogger: (tag: string, logger: Logger) => void; /** * Handles creating the logger and returning it * * @function * * @param {function|string=} context * @param {ILoggerConfiguration} config * @return {Logger} */ export declare const getLogger: <T>(context: string, config: ILoggerConfiguration) => Logger;