-
Notifications
You must be signed in to change notification settings - Fork 5
/
App.js
95 lines (88 loc) · 2.83 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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
import { StatusBar } from "expo-status-bar";
import { StyleSheet, Text, View } from "react-native";
import { Image } from "react-native";
import { NavigationContainer } from "@react-navigation/native";
import { createNativeStackNavigator } from "@react-navigation/native-stack";
import { createBottomTabNavigator } from "@react-navigation/bottom-tabs";
import LoginPage from "./screens/LoginPage";
import RegisterPage from "./screens/RegisterPage";
import FillLoginPage from "./screens/FillLoginPage";
import OtpPage from "./screens/OtpPage";
import VerifyEmail from "./screens/VerifyEmail";
import MapsPage from "./screens/MapsPage";
import MainPage from "./screens/MainPage";
import FillResources from "./screens/FillResources";
const Tab = createBottomTabNavigator();
import { Provider } from "react-redux";
import { configureStore } from "@reduxjs/toolkit";
import rootReducer from "./reducer";
const Stack = createNativeStackNavigator();
const store = configureStore({
reducer: rootReducer,
});
////////////////////////////////////////////////////////////////
// use this code for importing slices :)
// const token = useSelector(state => state.auth)
// console.log( "Token : " ,token);
export default function App() {
return (
// <View style={styles.container}>
// <Text>Home Page of Suraksha</Text>
// <StatusBar style="auto" />
// </View>
<Provider store={store}>
<NavigationContainer>
<Stack.Navigator initialRouteName="FillLoginPage">
<Stack.Screen
name="Login"
options={{ headerShown: false }}
component={LoginPage}
/>
<Stack.Screen
name="FillLoginPage"
component={FillLoginPage}
options={{ headerShown: false }}
/>
<Stack.Screen
name="RegisterPage"
component={RegisterPage}
options={{ headerShown: false }}
/>
<Stack.Screen
name="VerifyEmail"
component={VerifyEmail}
options={{ headerShown: false }}
/>
<Stack.Screen
name="OtpPage"
component={OtpPage}
options={{ headerShown: false }}
/>
<Stack.Screen
name="Maps"
component={MapsPage}
options={{ headerShown: false }}
/>
<Stack.Screen
name="FillResources"
component={FillResources}
options={{ headerShown: false }}
/>
<Stack.Screen
name="MainPage"
component={MainPage}
options={{ headerShown: false }}
/>
</Stack.Navigator>
</NavigationContainer>
</Provider>
);
}
const styles = StyleSheet.create({
container: {
flex: 1,
backgroundColor: "#fff",
alignItems: "center",
justifyContent: "center",
},
});