/** * Error Formatter - Claude Code style * Enhanced error message and stack trace formatting with robust handling * * Features: * - Consistent Claude Code styling with proper iconography * - Robust handling of malformed error objects * - Configurable stack trace depth * - Code context display with syntax highlighting * - Comparison errors for test assertions */ export interface ErrorInfo { type?: string; message: string; stack?: string; code?: string; file?: string; line?: number; column?: number; context?: string[]; cause?: Error | ErrorInfo; } export interface ErrorFormatOptions { showStack?: boolean; showContext?: boolean; maxStackLines?: number; compact?: boolean; showLineNumbers?: boolean; showCause?: boolean; } /** * Format error with enhanced styling * Handles malformed error objects gracefully */ export declare function formatError(error: Error | ErrorInfo | unknown, options?: ErrorFormatOptions): string; /** * Format multiple errors as a list */ export declare function formatErrorList(errors: Array, options?: ErrorFormatOptions): string; /** * Format TypeScript/compiler error */ export declare function formatCompilerError(file: string, line: number, column: number, message: string, code?: string): string; /** * Format validation errors */ export declare function formatValidationErrors(errors: Array<{ field: string; message: string; value?: any; }>): string; /** * Format error summary (count and types) */ export declare function formatErrorSummary(errors: Array): string; /** * Format diff-style error (expected vs actual) */ export declare function formatComparisonError(expected: any, actual: any, path?: string): string; /** * Format caught exception with context */ export declare function formatCaughtError(error: unknown, context?: string): string; //# sourceMappingURL=errorFormatter.d.ts.map