/** * Shared logger for @fjall/util and packages that depend on it (deploy-core, generator). * * By default, output goes to stderr. Consumers that need richer behaviour (Ink UI * suppression, file logging, structured JSONL) call {@link configureLogWriter} at * startup to redirect all output through their own logging infrastructure. * * Level gating (debug requires FJALL_DEBUG, trace requires FJALL_TRACE) is handled * here — the writer is only invoked for levels that pass the gate. */ export type LogLevel = "info" | "warn" | "error" | "debug" | "trace"; /** * Function that receives a log entry. The CLI replaces the default writer so * deploy-core output is routed through the CLI logger (which handles Ink * suppression, file rotation, and console formatting). */ export type LogWriter = (level: LogLevel, component: string, message: string, data?: Record) => void; /** * Replace the log writer. Call once at startup — typically the CLI calls this * to route deploy-core output through its own logger. */ export declare function configureLogWriter(writer: LogWriter): void; /** Reset to the default stderr writer (useful in tests). */ export declare function resetLogWriter(): void; export declare const logger: { info(component: string, message: string, data?: Record): void; warn(component: string, message: string, data?: Record): void; error(component: string, message: string, data?: Record): void; debug(component: string, message: string, data?: Record): void; trace(component: string, message: string, data?: Record): void; isDebugEnabled(): boolean; };