UNPKG

@cf-wasm/og

Version:

Generate Open Graph Images dynamically from HTML/CSS without a browser.

28 lines (27 loc) 996 B
/** Apis for loading emoji svg */ export declare const EMOJI_APIS: { openmoji: (code: string) => string; blobmoji: (code: string) => string; noto: (code: string) => string; twemoji: (code: string) => string; fluent: (code: string) => string; fluentFlat: (code: string) => string; }; /** Represents type of emoji */ export type EmojiType = keyof typeof EMOJI_APIS; export declare const toCodePoint: (unicodeSurrogates: string) => string; export declare const getIconCode: (char: string) => string; /** Emoji cache map */ export declare const EMOJI_CACHE_MAP: Map<string, string>; /** Default emoji type */ export declare const DEFAULT_EMOJI_TYPE: EmojiType; /** * A helper function for loading emoji svg * * @param code The emoji code * @param type The {@link EmojiType} * @param cacheStore The Cache to be used for caching svg responses * * @returns The emoji's svg as string */ export declare const loadEmoji: (code: string, type?: EmojiType) => Promise<string>;