lazysizes
lazysizes copied to clipboard
Images do not load when Chrome on Android's 'Lite Mode' enabled
Describe the bug
Images do not lazyload when Chrome on Android's 'Lite Mode' enabled.
Error occurs way often if there are multiple images at similar scroll positions so multiple images are failed to lazyload when triggered at same time, while Chrome on Android's Lite Mode enabled.
To Reproduce
Unfortunately no online reproduction is possible as it only occurs on Android when 'Lite Mode' from Chrome settings enabled.
To reproduce, please just visit any page that uses lazysizes library on any Android Chrome while Lite Mode from Chrome's advanced settings is enabled.
Steps to reproduce the behavior:
On Chrome Android (v83), load a page where images are not loaded with initial load, but are supposed to lazyload after scrolling down to their position.
What is the expected behavior
Lazyload images when scrolled down to their position.
What happened instead
Images are not loaded and an internal browser warning is logged to console as below:
[Intervention] Images loaded lazily and replaced with placeholders. Load events are deferred. See https://crbug.com/954323

And classes of not loaded images are stuck in 'lazyloading' instead of being 'lazyloaded'
In what environment (browser/device etc.) does this bug happen/not happen:
Only Chrome on Android (Probably after version 79, when Lite Mode was introduced)
I could not reproduce this issue on the demo page. (With enabled lite mode of course). Do you have more information or a webpage for me?
thank you for the library and the answer.
surely here is the reproducible website: www.skoove.com
it only happens if you scroll quickly to multiple images that are supposed to load at similar times and if images are not cached on disk of course.

you can see that it is stuck on lazyloading class, however without lite mode enabled, it works perfectly.
We also started seeing this on our site. Chrome 84 triggered it for us. Exactly the same symptoms as described by @loopbender
Android 10 LiteMode On