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

Styling react-native Navigation Drawer Items

$
0
0

How To styling react-native navigation drawer item's Text.I go through the Documentation but i didnt able to find correct way to do that

Navigation Documentation

This is My AppContainer

import React, { Component } from 'react';
import { connect } from 'react-redux';
import { View, Text, Button, StyleSheet } from 'react-native';
import { bindActionCreators } from 'redux';
import { ActionCreators } from '../actions';
import Home_ from './Home';
import About from './About';
//Add navigation
import { DrawerNavigator, DrawerItems} from 'react-navigation'

const cunstomeDrawerContentComponent = (props) => (
    <View style={{flex: 1, color: 'red',
        textAlign: 'center',
        fontSize: 30,
        fontFamily: 'cochin',
        letterSpacing: 4}} >
        <DrawerItems {...this.props} />
    </View>
);

const drawerLayout = DrawerNavigator({
    Home: { screen: Home_ },
    About: { screen: About },

});

function mapDispatchToProps(dispatch) {
    return bindActionCreators(ActionCreators, dispatch);
}

const styles = StyleSheet.create({
    container: {
        flex: 1, color: 'red',
        textAlign: 'center',
        fontSize: 30,
        fontFamily: 'cochin',
        letterSpacing: 4
    }


});

export default connect((state) => { return {} }, mapDispatchToProps)(drawerLayout);

Viewing all articles
Browse latest Browse all 16750

Trending Articles



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