-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathApp.js
52 lines (50 loc) · 1.73 KB
/
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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
import { Provider } from 'react-redux';
import { PersistGate } from 'redux-persist/integration/react';
import { NavigationContainer } from '@react-navigation/native';
import 'react-native-gesture-handler';
import { createStackNavigator } from '@react-navigation/stack';
import { FormRegistr } from './components/FormRegistr';
import { FormLogin } from './components/FormLogin';
import { Home } from './components/Home';
import { CommentsScreen } from './Screens/CommentsScreen';
import { MapScreen } from './Screens/MapScreen';
import { persistor, store } from './redux/store';
import { Text } from 'react-native';
const MainStack = createStackNavigator();
export default function App() {
return (
<Provider store={store}>
<PersistGate loading={null} persistor={persistor}>
<NavigationContainer>
<MainStack.Navigator initialRouteName="Login">
<MainStack.Screen
name="Registration"
component={FormRegistr}
options={{ headerShown: false }}
/>
<MainStack.Screen
name="Login"
component={FormLogin}
options={{ headerShown: false }}
/>
<MainStack.Screen
name="Home"
component={Home}
options={{ headerShown: false }}
/>
<MainStack.Screen
name="Comments"
component={CommentsScreen}
options={{ headerShown: false }}
/>
<MainStack.Screen
name="Map"
component={MapScreen}
options={{ headerShown: false }}
/>
</MainStack.Navigator>
</NavigationContainer>
</PersistGate>
</Provider>
);
}