Skip to main content

Constructor

Parameters

Partial<Record<Emoji, EmojiFormats>>

Returns

EmojiResolver

Methods

extend()

Add or override emoji mappings.

Parameters

fromGChat()

Convert a Google Chat unicode emoji to normalized EmojiValue. Returns an EmojiValue for the raw emoji if no mapping exists.

Parameters

string
required

Returns

EmojiValue

fromSlack()

Convert a Slack emoji name to normalized EmojiValue. Returns an EmojiValue for the raw emoji if no mapping exists.

Parameters

string
required

Returns

EmojiValue

fromTeams()

Convert a Teams reaction type to normalized EmojiValue. Teams uses specific names: like, heart, laugh, surprised, sad, angry Returns an EmojiValue for the raw reaction if no mapping exists.

Parameters

string
required

Returns

EmojiValue

matches()

Check if an emoji (in any format) matches a normalized emoji name or EmojiValue.

Parameters

string
required
string | EmojiValue
required

Returns

boolean

toDiscord()

Convert a normalized emoji (or EmojiValue) to Discord format (unicode). Discord uses unicode emoji, same as Google Chat.

Parameters

string | EmojiValue
required

Returns

string

toGChat()

Convert a normalized emoji (or EmojiValue) to Google Chat format. Returns the first GChat format if multiple exist.

Parameters

string | EmojiValue
required

Returns

string

toSlack()

Convert a normalized emoji (or EmojiValue) to Slack format. Returns the first Slack format if multiple exist.

Parameters

string | EmojiValue
required

Returns

string