0 points

jQuery Lazyload and AOS issue solution


dashboard

Sat Jul 25 2020 00:48:18 GMT+0000 (UTC)

Posted by @johannalexander #javascript

document.querySelectorAll('img')
    .forEach((img) =>
        img.addEventListener('load', () =>
            AOS.refresh()
        )
    );
content_copy Copy

I got the same problem currently with <img> and the loading="lazy" attribute. This fix works fine for me after AOS.init():