os:
iOS
version:
When react-native-swiper used with tab navigatiotr (react-navigation), after switch to other tabs a few time and switch back, the swiper turns out a white screen.
It is a problem only on iOS, while it works well on Android. I found if I set "removeClippedSubviews: false" in index.js of react-native-swiper, the problem seems solved. However I have not done further test yet.
os:
win 10 x64
version:
Hello, I have same issue on physical android device while Remote JS Debug is enabled . I have found that this issue is related to styles.
For example:
var stylesForSwipper = StyleSheet.create({
wrapper: {},
slide1: {
flex: 1,
backgroundColor: '#9DD6EB',
},
slide2: {
flex: 1,
backgroundColor: '#97CAE5',
},
})
And here is render() method:
<Swiper style={stylesForSwipper.wrapper} showsButtons={true}>
<View style={stylesForSwipper.slide1}>
...
</View>
<View style={stylesForSwipper.slide2}>
...
</View>
</Swiper>
This leads to white screen but navigation buttons are visible.
This issue occurs for me only if Remote JS Debug is enabled.
@saigyouyou same here I am also seeing the white screen.
by replacing line https://github.com/leecade/react-native-swiper/blob/master/src/index.js#L630
with contentOffset={{ x: 0, y: 0}} I was able to fix the issue.
Looks like there is something wrong with the offsetting in iOS.
@leecade @arribbar Any idea what could be the issue?
set this attribute on swiper removeClippedSubviews={false}
you should not use this attribute for large listViews.
@borvelt removeClippedSubviews={false} work for me
@borvelt removeClippedSubviews={false} work for me, thank you
@borvelt wrok for me too, thank you very much!
Most helpful comment
set this attribute on swiper
removeClippedSubviews={false}you should not use this attribute for large listViews.