Skip to content

getLogger

API Reference / @privatefolio/commons-node / logger / getLogger

getLogger(category?): Logger

Defined in: node_modules/@logtape/logtape/dist/logger.d.ts:692

Get a logger with the given category.

const logger = getLogger(["my-app"]);

The category of the logger. It can be a string or an array of strings. If it is a string, it is equivalent to an array with a single element.

string | readonly string[]

Logger

The logger.