const CustomHeaderButton = props => { return ( <HeaderButton {...props} IconComponent={Ionicons} iconSize={23} color={Platform.OS === 'android' ? 'white' : Colors.primary} /> ); }
createStackNavigator({ T1s: { screen:T1, navigationOptions: { headerTitle: 'T1', headerRight: <HeaderButtons HeaderButtonComponent={NavRightBtn}> <Item title='title' iconName='md-cloud' onPress={()=>{console.log('you pressed here')}} /> </HeaderButtons> } }, T2s: T2 }, { defaultNavigationOptions:{ headerStyle:{ backgroundColor: '#456' }, headerTintColor: '#678', title: 'T2' } })
// define IconComponent, color, sizes and OverflowIcon in one place const MaterialHeaderButton = (props) => ( <HeaderButton {...props} IconComponent={MaterialIcons} iconSize={23} color={colors.secondary} /> )
const AppHeaderIcon = (props) => ( <HeaderButton {...props} iconSize={24} IconComponent={Ionicons} color={Platform.OS === 'android' ? '#fff' : THEME.MAIN_COLOR} /> )
const NavRightBtn = (props) => { return( <HeaderButton {...props} IconComponent={Ionicons} iconSize={25} color={'#4f2'} /> ) }
const CustomHeaderButton = props => { return ( <HeaderButton {...props} IconComponent={Ionicons} iconSize={23} color={Platform.OS === 'android' ? 'white' : Colors.primary} /> ); }
const CustomHeaderButton = props => { return ( <HeaderButton {...props} IconComponent={Ionicons} iconSize={23} color={Platform.OS === "android" ? "white" : Colors.primary} /> ); }
const CustomHeaderButton = props => { return ( <HeaderButton {...props} IconComponent={Ionicons} iconSize={23} color={Platform.OS === 'android' ? 'white' : Colors.primary} /> ); }
const CustomHeaderButton = (props) => { return <HeaderButton {...props} IconComponent={Ionicons} iconSize={23} />; }