tabBarIcon : icon missing and Tab in Tab
First issue navigation problem.
Create a tab navigator top and bottom : work
Create a tab navigator in tab navigator : screen available but cannot be clicked
Missing icon
- try to using react-vector-icons and put in tabBarIcon Result : not show
- Try to put same thing in view Resullt : show
- Try to add "showIcon:true" Result: not show
- Try to using normal require at the tabBarIcon Result :now show
Example gist for testing https://gist.github.com/alien3d/cf43e3b255d38b2c3042bbd183833e5a
** in few hour i will try the same thing in osx platform ..
| software | version |
|---|---|
| react-navigation | 1.0.0-beta.11 |
| react-native | 0.46.4 |
| node | v6.11.0 |
| npm or yarn | 5.2.0 |
| platform | windows 7 |
| platform mobile test | android |
I have the same issue. Icon only renders on iOS phones, not on Android. Also, the tabs appear at the bottom of the screen on iOS, but at the the top on Android. What's going on?
@rickcha default android are at top and ios at the bottom. unless you override it. What annoy me about ios , most framework developer e.g ratchet css,xamarin and here also follow standard https://developer.apple.com/ios/human-interface-guidelines/overview/design-principles/
+1 same issue. The Icon tag worked in View but not TabBarIcon. Also there's no error thrown even when the "name" attribute was wrong like in the iOS case.
Another finding: It seems that the tabBarComponent is TabBarTop even if the tabPosition is set to "bottom". After add { tabBarComponent: TabBarBottom } the icon displayed just as in the iOS case.
Further investigation showed that the showIcon switch in TabBarTop was always false even when setting { showIcon: true } when initializing TabNavigator, which should be the cause of this bug. I also tried to set showIcon to false with TabBarBottom but the icon still appeared so maybe the tabOptions was not passed in correctly?
Silly me... The config should be { tabBarOptions: { showIcon: true } }. With this settings the tab icons can display icons correctly. It seems that it is a desired behavior instead of a bug.
As re-read the doc at https://reactnavigation.org/docs/navigators/tab. @yarray thank you. but still i yet not yet solve the tab in tab navigaton..
i solve it.. tab in tab issue.. some old duplicate issue check out again... but most of them no gist to follow up to check it out..
https://gist.github.com/alien3d/c8d9d1b3488bdc57d0bf06eb8d36e032