I am using the following code as a helper to render my emojis in my app:
import emojiMartData from "@emoji-mart/data";
import { init as emojiMartInit } from "emoji-mart";
emojiMartInit({ data: emojiMartData }); // 🍸
export function RenderEmoji({ native }: { native: string }) {
// @ts-expect-error Emoji mart somehow handles this component itself and typescript doesn't know about it so it's not too happy.
return <em-emoji native={native} skin="1" set="apple" />;
}
When using it in my other React components, the emojis are rendered perfectly just as I'd want them.
Sadly, I noticed this setup was downloading the images from the internet event if I took the data from the @emoji-mart/data package.
Is that expected behaviour? How can I make sure I use local downloaded images instead?
What
I am using the following code as a helper to render my emojis in my app:
When using it in my other React components, the emojis are rendered perfectly just as I'd want them. Sadly, I noticed this setup was downloading the images from the internet event if I took the data from the
@emoji-mart/data
package.Is that expected behaviour? How can I make sure I use local downloaded images instead?