UNPKG

@spot-meetings/backend-logger

Version:
36 lines (35 loc) 825 B
import winston from 'winston'; /** * @see https://github.com/winstonjs/winston#logging */ export declare enum LogLevel { Error = "error", Warn = "warn", Info = "info", Http = "http", Verbose = "verbose", Debug = "debug", Silly = "silly" } export declare enum LogOutput { Summary = "summary", Details = "details", Silent = "silent", Raw = "raw" } export declare const logIcons: Map<LogLevel, string>; export interface LogReporter { readonly version: string; readonly id: string; readonly ip: string; } export interface LogData { readonly reporter: LogReporter; readonly timestamp: string; stack?: string; [prop: string]: any; } /** * SpotLogger Class */ export declare const createLogger: (id: string, ip: string, version: string) => winston.Logger;