3
0
Fork 0
mirror of https://github.com/ZeppelinBot/Zeppelin.git synced 2025-05-19 16:05:01 +00:00

Add custom logger. Fix a bunch of errors. Optimize imports.

This commit is contained in:
Dragory 2020-07-22 22:56:21 +03:00
parent 2e28162012
commit 0c9a619880
89 changed files with 198 additions and 229 deletions

23
backend/src/logger.ts Normal file
View file

@ -0,0 +1,23 @@
// tslint-disable:no-console
export const logger = {
info(...args: Parameters<typeof console.log>) {
console.log("[INFO]", ...args);
},
warn(...args: Parameters<typeof console.warn>) {
console.warn("[WARN]", ...args);
},
error(...args: Parameters<typeof console.error>) {
console.error("[ERROR]", ...args);
},
debug(...args: Parameters<typeof console.log>) {
console.log("[DEBUG]", ...args);
},
log(...args: Parameters<typeof console.log>) {
console.log(...args);
},
};