I talk about it all the time, so it should come as no surprise that my favourite trick to avoiding XSS with complex HTML output is to use Laravel's HtmlString with {{ ... }}.
The less you use {!! ... !!}, the harder it is for XSS to hide! 🕵️
https://securinglaravel.com/security-tip-avoiding-xss-with-htmlstring/#Laravel