meliorence / react-native-snap-carousel

Swiper/carousel component for React Native featuring previews, multiple layouts, parallax images, performant handling of huge numbers of items, and more. Compatible with Android & iOS.
BSD 3-Clause "New" or "Revised" License
10.35k stars 2.29k forks source link

rerender when I move to other tab navigation #639

Open nguyenanh1 opened 4 years ago

nguyenanh1 commented 4 years ago

Is this a bug report, a feature request, or a question?

I have 4 tab and carousel are used by home. when i click tab 2 and tab 3 , i back to tab home then carousel hide and rerender item

Have you followed the required steps before opening a bug report?

(Check the step you've followed - put an x character between the square brackets ([]).)

Have you made sure that it wasn't a React Native bug?

(Write your answer here.)

Is the bug specific to iOS or Android? Or can it be reproduced on both platforms?

(Write your answer here and specify the iOS/Android versions on which you've been able to reproduce the issue.)

Is the bug reproductible in a production environment (not a debug one)?

(Write your answer here.)

Environment

(Write your answer here.)

Expected Behavior

(Write what you thought would happen.)

Actual Behavior

(Write what happened. Add screencasts/screenshots!)

Reproducible Demo

(Paste the link to a Snack example in which the issue can be reproduced. Please follow the guidelines for providing a Minimal, Complete, and Verifiable example.)

Steps to Reproduce

(Write your steps so that anyone can reproduce the issue in the Snack demo you provided.)

1. 2. 3.

azhararmar commented 4 years ago

Noticed the same behaviour, when switching between the tabs, carousel gets hidden, however my screen has parent when I scroll a bit, carousel again shows up.

nikechanhk commented 4 years ago

@azhararmar same here

nikechanhk commented 4 years ago

hey @azhararmar Just try set removeClippedSubviews to false can solve the problem 😂 But of course, it will decrease the performance of the list

dohooo commented 3 years ago

Sorry, please allow me to advertise for my open source library! ~ I think this library react-native-reanimated-carousel will solve your problem. It is a high performance and very simple component, complete with React-Native reanimated 2