Skip to content

Instantly share code, notes, and snippets.

@mauriciopazpp
Created July 11, 2018 02:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mauriciopazpp/7ad4cdbac91e70694a9d71b3239c3547 to your computer and use it in GitHub Desktop.
Save mauriciopazpp/7ad4cdbac91e70694a9d71b3239c3547 to your computer and use it in GitHub Desktop.
DrawerButton react native
const DrawerButton = (props) => {
return (
<View>
<TouchableOpacity onPress={() => {props.navigation.navigate('DrawerOpen')}}>
<Image
source={require('../img/iconImage.png')}
style={styles.icon}
/>
</TouchableOpacity>
</View>
);
};
const main_stack_nav = StackNavigator({
CategoryList: {
screen: RecipesCategoryList,
navigationOptions: ({navigation}) => ({
title: "Category List",
headerLeft: <DrawerButton navigation={navigation} />
}),
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment