-
Notifications
You must be signed in to change notification settings - Fork 0
/
App.tsx
53 lines (47 loc) · 1.33 KB
/
App.tsx
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 React from 'react';
import 'intl';
import 'intl/locale-data/jsonp/pt-BR';
import { NavigationContainer } from '@react-navigation/native';
import { ThemeProvider } from 'styled-components';
import AppLoading from 'expo-app-loading';
import { useFonts } from 'expo-font';
import { GestureHandlerRootView } from 'react-native-gesture-handler';
import { Provider } from 'react-redux';
import { PortalProvider } from '@gorhom/portal';
import {
Ubuntu_400Regular,
Ubuntu_700Bold
} from '@expo-google-fonts/ubuntu';
import {
Montserrat_300Light,
Montserrat_600SemiBold,
Montserrat_900Black
} from '@expo-google-fonts/montserrat';
import theme from './src/styles/theme';
import { Routes } from './src/routes';
import store from './src/store';
export default function App() {
const [ fontsLoaded ] = useFonts({
Ubuntu_400Regular,
Ubuntu_700Bold,
Montserrat_300Light,
Montserrat_600SemiBold,
Montserrat_900Black
});
if (!fontsLoaded) {
return <AppLoading />
}
return (
<Provider store={store}>
<NavigationContainer>
<GestureHandlerRootView style={{flex:1}}>
<ThemeProvider theme={theme}>
<PortalProvider>
<Routes/>
</PortalProvider>
</ThemeProvider>
</GestureHandlerRootView>
</NavigationContainer>
</Provider>
);
}