react-native-scrollable-tab-view icon indicating copy to clipboard operation
react-native-scrollable-tab-view copied to clipboard

ScrollableTabView inside view not rendering tab content

Open rangeshgupta-altair opened this issue 10 years ago • 4 comments

Is it possible to do something like this? Its not rendering the tab content. Also I need to tab twice to change the tab.

<View>
         <View><Text> Header </Text></View>
         </ScrollableTabView>
                    <Text tabLabel='tab1'>tab1</Text>
                    <Text tabLabel='tab2'>tab2</Text>
        </ScrollableTabView>
</View>

rangeshgupta-altair avatar Jul 08 '16 13:07 rangeshgupta-altair

You can pass renderTabBar={null} if you don't want tabs at all? Or do you want to have tabs in another place?

skv-headless avatar Jul 08 '16 16:07 skv-headless

Same issue here - when ScrollableTabView is within the View, it doesnt render any of the tab's content. Tab labels are display and clicking/switching works but no tab content(text) is displayed.

mateoKaradza avatar Jul 08 '16 20:07 mateoKaradza

@mateoKaradza : Issue has been resolved for me. Not sure because of the below changes on the code or I restarted the services and app because of that.

<View style={{flex:1}}> <View><Text> Header </Text></View> <View style={{flex:1}}> </ScrollableTabView> <Text tabLabel='tab1'>tab1</Text> <Text tabLabel='tab2'>tab2</Text> </ScrollableTabView> </View> </View>

rangeshgupta-altair avatar Jul 09 '16 02:07 rangeshgupta-altair

flex:1 solved it for me. thanks

damathryx avatar Sep 12 '16 12:09 damathryx