brainhubeu / react-carousel

A pure extendable React carousel, powered by Brainhub (craftsmen who ❤️ JS)
https://brainhub.eu/
MIT License
1.07k stars 164 forks source link

Carousel jumps when using "controlled" mode #529

Open Romcol opened 4 years ago

Romcol commented 4 years ago

Hi,

In controlled mode, my slider is sometimes jumping, instead of sliding, as shown in the video. When not in controlled mode, this problem is not present. Do you have any idea where it could come from?

Video Carousel bug

Environment System: OS: Linux 5.4 Debian GNU/Linux 9 (stretch) 9 (stretch) CPU: (12) x64 Intel(R) Core(TM) i7-8750H CPU @ 2.20GHz Memory: 1.60 GB / 15.27 GB Container: Yes Shell: 4.4.12 - /bin/bash Binaries: Node: 12.16.3 - /usr/local/bin/node Yarn: 1.22.4 - /usr/local/bin/yarn npm: 6.14.4 - /var/www/public/node_modules/.bin/npm

Cheers :)

piotr-s-brainhub commented 4 years ago

@Romcol

Thanks for reporting this.

Do you think it's related to that https://github.com/brainhubeu/react-carousel/issues/503 ?

Romcol commented 4 years ago

@piotr-s-brainhub Yes I think it does. Maybe this is a performance issue...

piotr-s-brainhub commented 4 years ago

@Romcol

Are you able to provide a code applicable in the clickable docs/demo?

Romcol commented 4 years ago

@piotr-s-brainhub

Hi, I've made this sandbox which reproduces the problem : https://codesandbox.io/s/react-playground-sbr19.

As soon as the component inside the carousel is a bit "heavy", it generated such issues.

piotr-s-brainhub commented 4 years ago

Thanks