first refactor
This commit is contained in:
parent
1f5dac28c7
commit
588f666943
84 changed files with 996 additions and 1062 deletions
|
|
@ -8,4 +8,4 @@
|
|||
export { Logger, getLogger, shutdownLoggers, setLoggerConfig } from './logger';
|
||||
|
||||
// Type definitions
|
||||
export type { LogLevel, LogContext, LogMetadata, LoggerConfig } from './types';
|
||||
export type { LogLevel, LogContext, LogMetadata, LoggerConfig, LoggerLike } from './types';
|
||||
|
|
|
|||
|
|
@ -1,10 +1,15 @@
|
|||
/**
|
||||
* Simplified type definitions for the logger library
|
||||
*/
|
||||
import type { Logger } from './logger';
|
||||
|
||||
// Standard log levels (simplified to pino defaults)
|
||||
export type LogLevel = 'trace' | 'debug' | 'info' | 'warn' | 'error' | 'fatal';
|
||||
|
||||
/** Logging capability accepted by adapters, including console-compatible loggers. */
|
||||
export type LoggerLike = Pick<Logger, Exclude<LogLevel, 'fatal'>> &
|
||||
Partial<Pick<Logger, 'child' | 'fatal'>>;
|
||||
|
||||
// Context that persists across log calls
|
||||
export interface LogContext {
|
||||
[key: string]: any;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue