How to use the logform.format.align function in logform

To help you get started, we’ve selected a few logform examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github breuerfelix / king-bot-api / src / logger.ts View on Github external
constructor() {
		const logFormat = format.combine(
			//format.colorize(),
			format.align(),
			format.printf((x: any) => `${x.level}: ${x.message}`)
		);

		this.log_inst = winston.createLogger({
			level: 'debug',
			format: logFormat,
			transports: [
				new winston.transports.Console()
			]
		});

		this.logz_inst = winston.createLogger({
			level: 'info',
			transports: [
				new logzio_transport({
					level: 'info',

logform

An mutable object-based log format designed for chaining & objectMode streams.

MIT
Latest version published 4 months ago

Package Health Score

89 / 100
Full package analysis