docs: set loading="lazy" on iframes (#2062)

This commit is contained in:
Eric Liu 2024-11-23 16:47:04 -08:00 committed by GitHub
commit 8ad7d5967e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -35,7 +35,7 @@
{/if}
<div class="preview-viewer" class:framed>
{#if framed}
<iframe title={src.split("/").pop()} src={themedSrcUrl}></iframe>
<iframe loading="lazy" title={src.split("/").pop()} src={themedSrcUrl}></iframe>
{:else}
<slot />
{/if}