Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Owl carousel infinite loop

What i am trying to achieve is to make my owl carousel infinite loop. after the last image slider revert to first image from right to left but i want my images not to revert back it mean after last image the first image will be came from left to right.

here is my code

$(document).ready(function() {
         $('.five').owlCarousel({
loop:true,
margin:10,
autoPlay:true,
nav:true,
rewindNav:false,
responsive:{
    0:{
        items:1
    },
    600:{
        items:3
    },
    1000:{
        items:4
    }
}
  })
    });
like image 472
Amit Chauhan Avatar asked Sep 01 '25 05:09

Amit Chauhan


1 Answers

When you use responsive class it always overwrite the top options.
So all you need is to add loop option to your responsive items.

responsive:{
  0:{
    items:1,
    loop:true
  },
  600:{
    items:3,
    loop:true
  },
  1000:{
    items:4,
    loop:true
  }
}
like image 100
Shahrzad Nazemi Avatar answered Sep 04 '25 10:09

Shahrzad Nazemi