hello, I'm using emojis in laravel, and in the part of sending to the blade, I convert the emojis to <img>, but this can XSS, could someone who has worked with emoji help me??
I thought of using js to convert all emojis by comments but I think it wouldn't work well...
$comment->comment = LaravelEmojiOneFacade::toImage($comment->comment);
//output: "<img class="emojione" alt="😀" title=":grinning:" src="https://cdn.jsdelivr.net/emojione/assets/4.0/png/64/1f600.png"/><button class='btn btn-primary'>Click</button>"
<p class="text-comment" style="overflow-wrap: break-word;">{!! html_entity_decode($comment['comment']) !!}</p>