I’m using ScrollableTabView for scrollable tab, in iOS I am able to set initiate page. But in android it not working
<ScrollableTabView
tabBarActiveTextColor={Colors.POLYCHROME_15}
initialPage={this.getInitialPage()}
tabBarUnderlineStyle={[
Styles.tabBarBorder
]}
locked={true}
style={Styles.tabBarContainer}
>
getInitialPage() {
const routesData = this.props.data;
const somethingData = this.props?.something;
let indexSomething = 0;
if (somethingData.length > 0) {
let dataEnable = [];
theDataFaq.map((dataSomethingEnable) => {
if (dataSomethingEnable.enable) {
dataEnable.push(dataFaqEnable)
}
})
if (dataEnable.length > 0) {
dataEnable.map((dataSomething, index) => {
if (routesData === dataSomething.something) {
indexSomething = index;
}
})
}
}
return indexSomething;
}
did i missing something? or there is some bugs ?
version of ScrollableTabView "react-native-scrollable-tab-view": "^1.0.0",
2
Answers
this should be able to fix this temporary:
set ref props for
then use setTimeOut (because scrollableTabView must be rendered first)
This is a bug in the newer versions.
Please use this version -> 0.6.0