Answer the question
In order to leave comments, you need to log in
How to disable autoplay in Slick?
I'm trying to disable autoplay in the slick slider on clicking the dot . I
found such options, but it doesn't work
// in general, it doesn't work, I probably didn't understand something in the design
$('.single-item-main').slick('slickPause');
$('.single-item-main').slick('slickSetOption', { 'autoplay': false }, false);
$('.single-item-main').slick({
draggable: true,
adaptiveHeight: true,
mobileFirst: true,
infinite: true,
dots: true,
slidesToShow: 1,
slidesToScroll: 1,
cssEase: 'linear',
accessibility: false,
arrows: false,
autoplay: true,
autoplaySpeed: 5000,
dotsClass: "my-dots",
pauseOnDotsHover: false,
pauseOnHover: false,
});
Answer the question
In order to leave comments, you need to log in
Eh...
well,
$('.single-item-main').slick('slickPause'); works.
When you click on the button, just write,
but the problem was that the script was connected twice, if anyone is interested
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question