Created
July 23, 2017 09:14
-
-
Save reyhansofian/c91eae138dad1324a0b736864b4b85b1 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// main.js | |
import Expo from 'expo'; | |
import React from 'react'; | |
import { StackNavigator } from 'react-navigation'; | |
import App from './src/App'; | |
import Film from './src/Film'; | |
import FilmDetail from './src/Film/FilmDetail'; | |
const routes = { | |
Home: { | |
name: 'Home', | |
screen: App, | |
}, | |
Film: { | |
name: 'Film', | |
screen: Film, | |
}, | |
FilmDetail: { | |
name: 'FilmDetail', | |
screen: FilmDetail, | |
}, | |
}; | |
const MainApp = StackNavigator(routes); | |
class AppContainer extends React.Component { | |
render() { | |
return ( | |
<ApolloProvider client={client}> | |
<MainApp /> | |
</ApolloProvider> | |
); | |
} | |
} | |
Expo.registerRootComponent(AppContainer); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment