UNPKG

@metricinsights/concierge

Version:

Metric Insights Concierge Component

29 lines 803 B
export declare abstract class BaseParser { abstract readonly id: string; abstract canParse(input: string, currentIndex: number): boolean; abstract parse(input: string, currentIndex: number): ParserResponse; } export type ParserResultType = 'html' | 'markdown' | 'latex' | 'element' | string; export interface ParserResult { type: ParserResultType; content: string; startIndex: number; endIndex: number; raw: string; } export interface ParserResponse { result: ParserResult | null; /** * The index of the next character to parse */ newIndex: number; } export interface ParserConfig { priority?: number; enabled?: boolean; } export interface ParserEntry { parser: BaseParser; config: ParserConfig; } //# sourceMappingURL=types.d.ts.map