-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathApp.js
37 lines (32 loc) · 994 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
34
35
36
37
import { StatusBar } from 'expo-status-bar';
import React, { useEffect } from 'react';
import { StyleSheet, Text, View } from 'react-native';
import { SafeAreaProvider } from 'react-native-safe-area-context';
import OnboardingStackScreen from './navigation/OnboardingStackScreen';
import Navigation from './navigation';
import * as SplashScreen from 'expo-splash-screen';
export default function App() {
// useEffect(() => {
// setTimeout(async () => {
// try {
// await SplashScreen.preventAutoHideAsync();
// } catch (error) {
// console.warn(error);
// }
// }, 0);
// return () => SplashScreen.hideAsync();
// }, [])
useEffect(() => {
setTimeout(async () => {
await SplashScreen.preventAutoHideAsync();
// await SplashScreen.hideAsync();
}, 0);
return () => SplashScreen.hideAsync();
}, [])
return (
<SafeAreaProvider>
<Navigation />
<StatusBar style="none"/>
</SafeAreaProvider>
);
}