Skip to main content

Variable: ParsedCustomEmojiWithGroups

const ParsedCustomEmojiWithGroups: RegExp

Regex that matches any animated or non-animated custom Discord emoji *without the wrapping <...> symbols. This means that a string that matches this regex can directly be send inside a Discord message. Other than this difference it is similar to FormattedCustomEmojiWithGroups.

Raw

/(?<animated>a?):(?<name>[^:]+):(?<id>\d{17,20})/

Remark

Capture group 1 can be used to determine whether the emoji is animated or not. It is named animated.

Remark

Capture group 2 is the name of the emoji as it is typed in a message. It is named name.

Remark

Capture group 3 is the ID of the emoji. It is named id.

Defined in

projects/utilities/packages/discord-utilities/src/lib/regexes.ts:95