UNPKG

@telegraf/entity

Version:

Convert Telegram entities to HTML or Markdown

9 lines (8 loc) 554 B
import * as serialisers from "./serialisers.js"; import * as escapers from "./escapers.js"; import type { Message, TextMessage, Tree } from "./types.js"; export declare function toTree(msg: TextMessage, offset?: number, upto?: number): Tree; declare const serialiseWith: (serialiser: typeof serialisers.HTML, escaper: typeof escapers.HTML) => (message: Message) => string; declare const toHTML: (message: Message) => string; declare const toMarkdownV2: (message: Message) => string; export { serialisers, escapers, serialiseWith, toHTML, toMarkdownV2 };