/** * Context information to be included with errors for better debugging */ export interface ErrorContext { /** The URL where the error occurred (if applicable) */ url?: string; /** HTML content that was being processed (truncated for large content) */ html?: string; /** Markdown content that was being generated (truncated for large content) */ markdown?: string; /** Any additional helpful context information */ [key: string]: unknown; } /** * Base error class for all markdown-read errors * Stores rich context information to aid in debugging */ export declare class BaseError extends Error { readonly context: ErrorContext; readonly cause?: Error | undefined; /** * Create a new BaseError with context information * * @param message - Human-readable error message * @param context - Additional context information for debugging * @param cause - The original error that caused this error */ constructor(message: string, context?: ErrorContext, cause?: Error | undefined); /** * Get a string representation of the error with context */ toString(): string; /** * Truncates large context values to prevent memory issues * and ensure errors are readable */ private truncateContextValues; }