JSFiddle - React, Tailwind, and code Playground

HTML

<script src="https://cdn.jsdelivr.net/npm/vanilla-lazyload@17.8.4/dist/lazyload.min.js"></script>

<img style="width:100%" alt="A lazy image" class="lazy" data-src="https://images.unsplash.com/photo-1695606392809-0da228da6b83?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=2070&q=80" /><br>

    <img style="width:100%" alt="A lazy image" class="lazy" data-src="https://images.unsplash.com/photo-1695637453789-428d537b1ff0?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=1887&q=80" /><br>

    <img style="width:100%" alt="A lazy image" class="lazy" data-src="https://images.unsplash.com/photo-1695367255190-07523220640b?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=2070&q=80" /><br>

    <img style="width:100%" alt="A lazy image" class="lazy" data-src="https://images.unsplash.com/photo-1695662596747-03e9d3aee778?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=1886&q=80" /><br>

    <img style="width:100%" alt="A lazy image" class="lazy" data-src="https://images.unsplash.com/photo-1695456527397-0b9e1c79fe96?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=2070&q=80" /><br>

    <img style="width:100%" alt="A lazy image" class="lazy" data-src="https://images.unsplash.com/photo-1695367255569-85b0536aeed2?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=2070&q=80" /><br>

    <img style="width:100%" alt="A lazy image" class="lazy" data-src="https://images.unsplash.com/photo-1694802491008-a528234a9a2d?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=1887&q=80" /><br>

    <img style="width:100%" alt="A lazy image" class="lazy"...

JavaScript

var lazyLoadInstance = new LazyLoad({
    // Your custom settings go here
  });