diff --git a/src/components/emoji-text.jsx b/src/components/emoji-text.jsx index 441836c5..2200aadf 100644 --- a/src/components/emoji-text.jsx +++ b/src/components/emoji-text.jsx @@ -17,12 +17,17 @@ function EmojiText({ text, emojis }) { // 'g', // ); const regex = shortcodesRegexp(emojis.map((e) => e.shortcode)); - const elements = text.split(regex).map((word) => { + const elements = text.split(regex).map((word, i) => { const emoji = emojis.find((e) => e.shortcode === word); if (emoji) { const { url, staticUrl } = emoji; return ( - + = 2 same shortcodes + /> ); } return word;