On my website https://bitcoin-2go.de I am frequently embeding videos from our youtube-channel or using the embed function for twitter cards.
However, I’ve realized that all iframes are not shipped with a lazy-loading attribute. Therefore, the page speed and performance of those single posts suffers significantly.
What I would like to do now, is adopting the source-code which is responsible for rendering the bookmark cards.
Thus far, I’ve checked the github-repository and I think that
is the file that needs to be manipulated in order to add
loading="lazy" to the iframes.
It would be great to get some response and feedback on how I could manipulate the payload and iframe-element such that it automatically enables lazy loading.
Thanks in advance!