import { LogErrorOptions, LogOptions } from 'vite'; import { Logger as ViteLogger } from "vite"; declare const LogLevels: { error: number; warn: number; info: number; }; interface ILoggerOptions { logLevel?: number; logFilter?: (params: ILogParams) => boolean; } interface ILogParams { level: keyof typeof LogLevels; msg?: string; options?: LogErrorOptions; } /** * Default production logger */ declare class Logger implements ViteLogger { /** * @inheritDoc */ hasWarned: boolean; /** * Current log level */ loglevel: number; /** * Custom log filter * Return 'true' to skip output */ logFilter: ILoggerOptions['logFilter'] | undefined; /** * @constructor */ /** * @constructor */ constructor({ logFilter, logLevel }?: ILoggerOptions); /** * @inheritDoc */ /** * @inheritDoc */ clearScreen(): void; /** * Should we skip current log depends on current log level */ /** * Should we skip current log depends on current log level */ protected shouldSkipLog(level: number): boolean; /** * Common log */ /** * Common log */ protected log(params: ILogParams): void; /** * @inheritDoc */ /** * @inheritDoc */ error(msg: string, options?: LogErrorOptions): void; /** * @inheritDoc */ /** * @inheritDoc */ hasErrorLogged(): boolean; /** * @inheritDoc */ /** * @inheritDoc */ info(msg: string, options: LogOptions): void; /** * @inheritDoc */ /** * @inheritDoc */ warn(msg: string, options: LogOptions): void; /** * @inheritDoc */ /** * @inheritDoc */ warnOnce(msg: string, options: LogOptions): void; } export { Logger as default };