UNPKG

@dkoul/auto-testid-core

Version:

Core AST parsing and transformation logic for React and Vue.js attribute generation

45 lines 1.71 kB
export type LogLevel = 'error' | 'warn' | 'info' | 'debug' | 'verbose'; export interface LoggerOptions { level?: LogLevel; prefix?: string; timestamp?: boolean; colorize?: boolean; } export declare class Logger { private static globalLevel; private options; private readonly LOG_LEVELS; private readonly COLORS; constructor(prefix?: string, options?: LoggerOptions); static setGlobalLevel(level: LogLevel): void; static getGlobalLevel(): LogLevel; error(message: string, ...args: any[]): void; warn(message: string, ...args: any[]): void; info(message: string, ...args: any[]): void; debug(message: string, ...args: any[]): void; verbose(message: string, ...args: any[]): void; time(label: string): void; timeEnd(label: string): void; group(label: string): void; groupEnd(): void; table(data: any[]): void; private log; private shouldLog; private formatMessage; private getLogMethod; child(prefix: string, options?: Partial<LoggerOptions>): Logger; progress(current: number, total: number, message?: string): void; private createProgressBar; metrics(label: string, metrics: Record<string, number | string>): void; exception(error: Error | unknown, context?: string): void; } export declare const logger: Logger; export declare const log: { error: (message: string, ...args: any[]) => void; warn: (message: string, ...args: any[]) => void; info: (message: string, ...args: any[]) => void; debug: (message: string, ...args: any[]) => void; verbose: (message: string, ...args: any[]) => void; setLevel: (level: LogLevel) => void; }; //# sourceMappingURL=logger.d.ts.map