Guest User

Untitled

a guest
Oct 23rd, 2019
97
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. import React from 'react'
  2. import { createAppContainer } from 'react-navigation'
  3. import { createStackNavigator } from 'react-navigation-stack'
  4. import Home from './screens/Home'
  5. import Browser from './screens/Browser'
  6.  
  7. const HomeStack = createStackNavigator({
  8. Home: {
  9. screen: Home,
  10. navigationOptions: ({ navigation }) => ({
  11. title: 'Home',
  12. headerTintColor: 'blue'
  13. })
  14. },
  15. Browser: {
  16. screen: Browser,
  17. navigationOptions: ({ navigation }) => ({
  18. title: navigation.state.params.title,
  19. headerTintColor: 'green'
  20. })
  21. }
  22. })
  23.  
  24. const AppContainer = createAppContainer(HomeStack)
  25.  
  26. export default AppContainer
RAW Paste Data