Skip to main content

Built and signed on GitHub Actions

Library for formatting text for Telegram Bot API

This package works with Cloudflare Workers, Node.js, Deno, Bun, Browsers
This package works with Cloudflare Workers
This package works with Node.js
This package works with Deno
This package works with Bun
This package works with Browsers
JSR Score
100%
Published
2 months ago (0.1.5)
function customEmoji
customEmoji(
custom_emoji_id: string,
): FormattableString

Insert custom emoji by their id.

Examples

Example 1

customEmoji("⚔️", "5222106016283378623")
format`test ${customEmoji("⚔️", "5222106016283378623")}`

NOTE: Custom emoji entities can only be used by bots that purchased additional usernames on Fragment.

Parameters

custom_emoji_id: string

Return Type

Add Package

deno add jsr:@gramio/format

Import symbol

import { customEmoji } from "@gramio/format";

---- OR ----

Import directly with a jsr specifier

import { customEmoji } from "jsr:@gramio/format";

Add Package

npx jsr add @gramio/format

Import symbol

import { customEmoji } from "@gramio/format";

Add Package

yarn dlx jsr add @gramio/format

Import symbol

import { customEmoji } from "@gramio/format";

Add Package

pnpm dlx jsr add @gramio/format

Import symbol

import { customEmoji } from "@gramio/format";

Add Package

bunx jsr add @gramio/format

Import symbol

import { customEmoji } from "@gramio/format";