I’ve been trying to uncover the best way of adding width and height attributes to my website logos to improve CLS. Interestingly, I see that Elementor has done so in their latest design:
I noted that they used the Icon widget, instead of the Site Logo widget. I attempted to do the same, but noticed that it isn’t really possible to replicate from the interface. We can only add HTML attributes to the wrapper, not the element itself.
Any thoughts on the best approach to accomplish this? I’m guessing they used a hardcoded PHP function to do it, as shown here:
Is there a better way that I am overlooking?
Best answer by skamericaView original