Answer the question
In order to leave comments, you need to log in
How to change the carousel?
Friends, do not tell me why when there is 1 object in the carousel, it is duplicated by the number specified in js. How to make sure that it is not duplicated, but the settings for the number of output are preserved.
https://codepen.io/Nelis/pen/reEjZz
Answer the question
In order to leave comments, you need to log in
var count_items = $('.owl-carousel .item').length;
$('.owl-carousel').owlCarousel({
…
responsive: {
0: {
items: 1
},
600: {
items: count_items >= 3 ? 3 : count_items
},
1000: {
items: count_items >= 5 ? 5 : count_items
}
}
})
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question