Open lillogoal opened 5 years ago
In this moment i solved using this answer: https://github.com/facebook/react-native/issues/6849#issuecomment-513902755
But i think the problem is only in Android because not exist a method to set initial position ScrollView
"react-native": "0.61.2",
"react-native-swiper": "^1.6.0-rc.3",
Same issue here with Android. The workarround with the overlay work but need a better solution...
this only happens when I first map some data to a list of components
{array.map(a => (
<Text>{a}</Text>
))}
If I just pass a bunch of views initially onIndexChange works as expected.
Which OS ?
Android and maybe too IOS
Version
Which versions are you using: "react": "16.9.0", "react-native": "0.61.3", "react-native-swiper": "1.6.0-rc.3",
Expected behaviour
This is my Component where i use Swiper. <View style={{ flex: 1 }}> <Swiper style={styles.wrapper} showsButtons={false} index={1} ref={(ref: Swiper) => { this.swiperMain = ref }} horizontal={true} onIndexChanged={index => this.onIndexChanged(index)} showsPagination={false}
I setted initial index = 1 ad it's ok. But when i launch app (in particular in android) i can see before render index = 1, swiper renders index = 0 in my case Profile. I have been looked for solving this problem on github or google but i didn't find anything
I can record a little video if you want