I use the autoplay function in slick slider to change the slides every 10 seconds:
jQuery(window).on('load resize', function () {
jQuery('.slider').not('.slick-initialized').slick({
arrows: false,
dots: true,
autoplay: true,
autoplaySpeed: 10000,
speed: 1500
});
});
The autoplaySpeed function starts counting when the page is loaded but i want to start the count just when the slick-element comes into view. How is it possible to load the slider on page load but start autoplay when the element arrives in the viewport?