-
Notifications
You must be signed in to change notification settings - Fork 0
/
App.js
53 lines (47 loc) · 1.49 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
import 'react-native-gesture-handler';
import React, { useEffect } from 'react';
import { StatusBar } from 'react-native';
import RNBootSplash from "react-native-bootsplash";
import { Provider } from 'react-redux';
import { PersistGate } from 'redux-persist/integration/react';
import { SafeAreaProvider } from 'react-native-safe-area-context';
import { NavigationContainer } from '@react-navigation/native';
import { createNativeStackNavigator } from '@react-navigation/native-stack';
import { Home, Settings, Tutorial } from './src/screens';
import configureStore from './src/store/configureStore';
const store = configureStore();
const Stack = createNativeStackNavigator();
const App = () => {
useEffect(() => {
RNBootSplash.hide({ fade: true });
});
return (
<SafeAreaProvider>
<Provider store={store.store}>
<PersistGate loading={null} persistor={store.persistor}>
<StatusBar backgroundColor="#111827" />
<NavigationContainer>
<Stack.Navigator
screenOptions={{
headerShown: false,
animation: 'slide_from_right',
presentation: 'modal',
}}
>
<Stack.Screen name="Home" component={Home} />
<Stack.Screen name="Settings" component={Settings} />
<Stack.Screen
name="Tutorial"
component={Tutorial}
options={{
animation: 'slide_from_bottom'
}}
/>
</Stack.Navigator>
</NavigationContainer>
</PersistGate>
</Provider>
</SafeAreaProvider>
);
};
export default App;