I'm using OWL Carousel, trying to add class .border-red
to <div class="item">
after lazyLoad, means call this function after lazyLoad afterLazyLoad
Example: $(".item").addClass("border-red");
when lazy loaded. Means add class function execute after OWLCarousel lazyLoaded.
JS
$(document).ready(function() {
$("#owl-demo").owlCarousel({
items : 4,
lazyLoad : true,
navigation : true
});
});
HTML
<div id="owl-demo" class="owl-carousel">
<div class="item"><img class="lazyOwl" data-src="assets/owl1.jpg" alt="Lazy Owl Image"></div>
<div class="item"><img class="lazyOwl" data-src="assets/owl1.jpg" alt="Lazy Owl Image"></div>
<div class="item"><img class="lazyOwl" data-src="assets/owl2.jpg" alt="Lazy Owl Image"></div>
<div class="item"><img class="lazyOwl" data-src="assets/owl3.jpg" alt="Lazy Owl Image"></div>
<div class="item"><img class="lazyOwl" data-src="assets/owl5.jpg" alt="Lazy Owl Image"></div>
</div>
Here is OWLCarousel Options and Callbacks
OWLCarousel demo >
How to addclass function execute after OWLCarousel lazyLoaded?