forked from diego-aquino/taskboard-mobile
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathApp.jsx
32 lines (27 loc) · 864 Bytes
/
App.jsx
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
import 'react-native-gesture-handler';
import SplashScreen from 'expo-app-loading';
import React from 'react';
import { AccountContextProvider } from '~/contexts/AccountContext';
import { AuthContextProvider } from '~/contexts/AuthContext';
import { GlobalSettingsContextProvider } from '~/contexts/GlobalSettingsContext';
import { useFonts } from '~/hooks';
import Routes from '~/routes';
import { Container } from '~/styles/AppStyles';
const App = () => {
const [fontsAreLoaded] = useFonts();
if (!fontsAreLoaded) {
return <SplashScreen />;
}
return (
<AuthContextProvider>
<GlobalSettingsContextProvider>
<AccountContextProvider>
<Container>
<Routes />
</Container>
</AccountContextProvider>
</GlobalSettingsContextProvider>
</AuthContextProvider>
);
};
export default App;