I am using the react-slick Slider Component to display a set of images. after the user crosses some slide position I am calling another API and appending the new results with the existing results using old.concat(new) stored in component state. Each time when the API is called, the slider displays 2 rows(its height is changed) and then adjust its height again. Once the API data is added to the array, is there is a glitch that disturbs the slider and then fixes after few seconds? or is it issue with my code? How do I fix this issue?
I am using the react-slick Slider Component to display a set of images. after the user crosses some slide position I am calling another API and appending the new results with the existing results using old.concat(new) stored in component state. Each time when the API is called, the slider displays 2 rows(its height is changed) and then adjust its height again. Once the API data is added to the array, is there is a glitch that disturbs the slider and then fixes after few seconds? or is it issue with my code? How do I fix this issue?
I created CodeSandBox to replicate the issue here: https://codesandbox.io/s/react-slick-playground-forked-ub5fy