mirror of
https://github.com/RooVetGit/Roo-Code.git
synced 2026-08-28 05:27:24 +00:00
25 lines
640 B
TypeScript
25 lines
640 B
TypeScript
/**
|
|
* @fileoverview Main entry point for the compact logging system
|
|
* Provides a default logger instance with Jest environment detection
|
|
*/
|
|
|
|
import { CompactLogger } from "./CompactLogger"
|
|
|
|
/**
|
|
* No-operation logger implementation for production environments
|
|
*/
|
|
const noopLogger = {
|
|
debug: () => {},
|
|
info: () => {},
|
|
warn: () => {},
|
|
error: () => {},
|
|
fatal: () => {},
|
|
child: () => noopLogger,
|
|
close: () => {},
|
|
}
|
|
|
|
/**
|
|
* Default logger instance
|
|
* Uses CompactLogger for normal operation, switches to noop logger in Jest test environment
|
|
*/
|
|
export const logger = process.env.NODE_ENV === "test" ? new CompactLogger() : noopLogger
|