Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Elementor Slider Pro with Swiper Slider issues using background images using CSS instead of HTML

See Swiper Slider Lazy Loading example. The Elementor Slider Widget Pro uses Swiper and basic setup uses background images with CSS [link]. They do not use HTML tags like <div> or <img> with src, data-src or srcset . To use lazy loading HTML markup has to be changed as shown in example.

With this HTML markup that we could also use Imagify to load webP images when possible using swapping with JavaScript. Unfortunately this is not possible with the current setup of Elementor Slider Pro.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment