mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2024-12-18 03:01:54 -05:00
57675265fc
Signed-off-by: Philip Molares <philip.molares@udo.edu> Signed-off-by: David Mehren <dmehren1@gmail.com>
20 lines
435 B
TypeScript
20 lines
435 B
TypeScript
import { createLogger, format, transports } from 'winston'
|
|
|
|
const logger = createLogger({
|
|
level: 'debug',
|
|
format: format.combine(
|
|
format.uncolorize(),
|
|
format.timestamp(),
|
|
format.align(),
|
|
format.splat(),
|
|
format.printf(info => `${info.timestamp} ${info.level}: ${info.message}`)
|
|
),
|
|
transports: [
|
|
new transports.Console({
|
|
handleExceptions: true
|
|
})
|
|
],
|
|
exitOnError: false
|
|
})
|
|
|
|
export { logger }
|