GoonCord/src/lib/utils/logger.ts
2024-05-22 03:02:13 +08:00

15 lines
429 B
TypeScript

import { findByNameProxy } from "@metro/utils";
export type LoggerFunction = (...messages: any[]) => void;
export interface Logger {
log: LoggerFunction;
info: LoggerFunction;
warn: LoggerFunction;
error: LoggerFunction;
time: LoggerFunction;
trace: LoggerFunction;
verbose: LoggerFunction;
}
export const logModule = findByNameProxy("Logger");
export const logger: Logger = new logModule("Bunny");