UNPKG

html-content-processor

Version:

A professional library for processing, cleaning, filtering, and converting HTML content to Markdown. Features advanced customization options, presets, plugin support, fluent API, and TypeScript integration for reliable content extraction.

39 lines (38 loc) 2.35 kB
/** * HTML Filter Strategy Library * * A comprehensive library for cleaning, filtering, and converting HTML content * to Markdown with advanced customization options, presets, and plugin support. * * @author HTML Filter Strategy Team * @license MIT */ import { VERSION, API_VERSION, getVersionInfo } from './version'; export { HtmlProcessor } from './html-processor'; export { HtmlFilter } from './html-filter'; export { DefaultMarkdownGenerator } from './markdown-generator'; export { domAdapter, parseHTML, getDOMParser, getDocument, isNode, isBrowser } from './dom-adapter'; export { ProcessorOptions, FilterOptions, ConverterOptions, ConvertOptions, FilterResult, MarkdownResult, FilterMetadata, MarkdownMetadata, Plugin, PluginContext, PresetName, ProcessorError, FilterError, ConversionError, PluginError, MarkdownGenerationResult, Html2TextOptions } from './types'; export { PageTypeDetector, pageTypeDetector, PageTypeResult, PageType, PageCharacteristics } from './page-type-detector'; export { htmlToMarkdown, htmlToMarkdownWithCitations, htmlToText, cleanHtml, extractContent, htmlToArticleMarkdown, htmlToBlogMarkdown, htmlToNewsMarkdown, strictCleanHtml, gentleCleanHtml, createProcessor, htmlToMarkdownAuto, cleanHtmlAuto, extractContentAuto } from './convenience-api'; export { presets, getPreset, getPresetNames, hasPreset, mergeWithPreset } from './presets'; export { usePlugin, removePlugin, getPlugin, hasPlugin, getAllPlugins, getPluginNames, clearPlugins, getPluginStats, builtinPlugins, useBuiltinPlugins } from './plugin-manager'; export { VERSION, API_VERSION, getVersionInfo }; import { HtmlProcessor } from './html-processor'; import { htmlToMarkdown, htmlToMarkdownWithCitations, htmlToText, cleanHtml, extractContent, createProcessor } from './convenience-api'; /** * Main API object - Clean and simple interface */ declare const htmlFilterAPI: { HtmlProcessor: typeof HtmlProcessor; htmlToMarkdown: typeof htmlToMarkdown; htmlToMarkdownWithCitations: typeof htmlToMarkdownWithCitations; htmlToText: typeof htmlToText; cleanHtml: typeof cleanHtml; extractContent: typeof extractContent; createProcessor: typeof createProcessor; version: string; apiVersion: string; getVersionInfo: typeof getVersionInfo; }; export default htmlFilterAPI;