akiran / react-slick

React carousel component
http://react-slick.neostack.com/
MIT License
11.72k stars 2.1k forks source link

Child components unmounting and remounting #2074

Open HIkkigayaH opened 3 years ago

HIkkigayaH commented 3 years ago

Guidelines for posting a new issue

The Slider component seems to unmount and the remount all its children. At least all the numbers appearing twice in the console indicates so. I have a component that does some fetch requests in the useEffect(()=>...,[]) part but because of the mentioned behavior my components are make API calls 2 times. I don't know if it is an expected behavior or not.

Sandbox Link: https://codesandbox.io/s/react-slick-playground-forked-oqbhv image

abhizuddl commented 1 year ago

@akiran Please take a look at this.