Owl Carousel 2 slider crashes when swiping on mobile (Iphone 11 pro)

1.5k views Asked by At

I'm having crashing issue on mobile when swiping owl carousel slider, especially with iphone 11 pro using safari and chrome. All other sliders works fine but one group/slider crashes the whole application when I perform swiping. I cannot debug the issue even on browserstack. I can only see it crash.

Can someone give me leads on how to fix this?

2

There are 2 answers

0
jona On

I tested it out several times, and this issues seems to be happening only on Iphone (during swiping process only).

My best guess of the bug might be due to the animation transition, adding the options

'smartSpeed': 0

for mobile view resolve the issue for me.

1
walnut-guru On

Not sure if you figured this out yet or not since it's been a few months but posting in case others have this issue.

I came across your post because I was getting the same error on iPhone 11 Pros and isolated it as coming from Owl Carousel. Your mention of having other slider work fine actually clued me into what was happening and made me realize that it must be one of the options. I tested by removing all all the options I had included in the Owl Carousel script an I stopped seeing the error on the phone. Then to identify who the problem was I added the options back 1 at a time until I got the error again. It seems that if you have loop: true, set on it causes the site to crash on iPhone 11, iPhone 11 Pro and iPhone 11 Pro Max.

Then to resolve the issue I used the responsive option to set loop to true only for desktop sizes. It's a super odd bug and hopefully Owl Carousel addresses it soon.