v2.0.1
Introducing <NakedImage />
Now that both loading=lazy
and aspect-ratio
are broadly supported (> 93% of browsers) we can avoid complex JS to achieve lazy-loaded images with placeholders!
<NakedImage />
generates minimum JS footprint, outputs a single <picture />
element and implements lazy-loading using the native loading="lazy"
attribute. The placeholder is set as the background to the image itself.