Quantcast
Channel: Active questions tagged react-native+android - Stack Overflow
Viewing all articles
Browse latest Browse all 29970

Is it possible to add an icon to top tab navigator in React Native Router Flux?

$
0
0

I want to add an icon to every scene (tab) in the <Tabs></Tabs> component from react-native-router-flux.

I've noticed that the icons do indeed show when tabBarPosition="bottom".

My code looks similar to this:

<Stack><Tabs tabBarPosition="top"><Scene icon={({focused}) => (<Icon name="star" />    )} hideNavBar /><Scene icon={({focused}) => (<Icon name="audiotrack" />    )} initial hideNavBar /><Scene icon={({focused}) => (<Icon name="album" />    )} hideNavBar /></Tabs></Stack>

(Note that I've only included code related to my problem, nothing else)

Icons for Tab navigators with tabBarPosition={true} should be available in the component, as is evident in react-navigation's createMaterialTopTabNavigator as well as the documentation of react-native-router-flux, and I'm not sure if I'm doing something wrong or if this feature is not implemented for a reason.


Viewing all articles
Browse latest Browse all 29970

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>