2 HTML Lazy Loading Examples
This collection focuses on the power of the native loading="lazy" attribute for images and iframes, now supported by all modern browsers. It demonstrates how to implement the attribute correctly to boost Core Web Vitals (specifically LCP) without a single line of JavaScript. The guide also explains how to prevent Cumulative Layout Shift (CLS) by properly combining lazy loading with width and height attributes or CSS aspect ratios. These are zero-dependency solutions for instantly faster initial page loads.
Examples

Responsive Fluid Photo Gallery Grid
This is a Responsive Fluid Photo Gallery Grid. It organizes varied aspect-ratio images into justified rows without cropping essential content. Its primary function is to optimize visual space, ensuring edge-to-edge alignment while deferring offscreen asset loading for strict performance control. (Requires: lazysizes, object-fit-images)
See the Pen Responsive Fluid Photo Gallery Grid.

Pure HTML/CSS Image Slideshow
A lightweight, fast gallery that operates without JS libraries, supporting keyboard navigation, mobile swipes, and deep linking to specific slides.
See the Pen Pure HTML/CSS Image Slideshow.