I have a tabBar navigator and i want to replace the icons with images, it's working but the activeTintColor won't change when focused although it's set in the navigationOptions, here is the code:
TabBarIcon component
export default class TabBarIcon extends React.Component {
render() {
return (
<Image
source={this.props.source}
tintColor={this.props.focused ? Colors.tabIconSelected : Colors.tabIconDefault}
/>
);
}
}
Icon in tabBarNavigator
tabBarIcon: ({ focused, tintColor }) => (
<Image
focused={focused}
source={require('/assets/images/icon.png')}
tintColor={tintColor}
/>
),