import TurndownService from 'turndown'; /** * 记录异步函数执行时间的装饰器函数 * @param label 日志标签 */ export declare function timeExecutionAsync(fn: () => Promise, label?: string): Promise; /** * 记录同步函数执行时间的工具函数 * @param fn 要执行的函数 * @param label 日志标签 */ export declare function timeExecutionSync(fn: () => T, label?: string): T; /** * 安全解析JSON字符串 * @param jsonString JSON字符串 * @param defaultValue 解析失败时的默认值 */ export declare function safeJsonParse(jsonString: string, defaultValue: T): T; /** * 延迟指定的毫秒数 * @param ms 毫秒数 */ export declare function delay(ms: number): Promise; /** * 深度合并对象 * @param target 目标对象 * @param source 源对象 */ export declare function deepMerge(target: T, source: Partial): T; /** * 将HTML转换为Markdown * @param html 要转换的HTML字符串 * @param options Turndown服务选项 * @returns 转换后的Markdown字符串 */ export declare function convertHtmlToMarkdown(html: string, options?: TurndownService.Options): string;