-
Notifications
You must be signed in to change notification settings - Fork 1
/
App.js
34 lines (29 loc) · 943 Bytes
/
App.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
import React from 'react';
import { StyleSheet, Text, View } from 'react-native';
import { LoginScreen } from "./screens/LoginScreen/LoginScreen";
import { MapScreen } from "./screens/MapScreen/MapScreen";
import { SwipeScreen } from "./screens/SwipeScreen/SwipeScreen";
import { ReviewScreen } from "./screens/ReviewScreen/ReviewScreen";
import { createBottomTabNavigator, createSwitchNavigator, createAppContainer } from 'react-navigation';
import { AppProvider } from './AppProvider';
const TabNavigator = createBottomTabNavigator({
map: MapScreen,
swipe: SwipeScreen,
review: ReviewScreen
});
const MainNavigator = createSwitchNavigator({
auth: LoginScreen,
main: TabNavigator
}, {
initialRouteName: "main"
})
const AppContainer = createAppContainer(MainNavigator);
export default class App extends React.Component {
render() {
return (
<AppProvider>
<AppContainer />
</AppProvider>
);
}
}