-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathApp.tsx
36 lines (28 loc) · 787 Bytes
/
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
import './translation';
import 'react-native-gesture-handler';
import { useFonts } from 'expo-font';
import * as SplashScreen from 'expo-splash-screen';
import React, { useEffect } from 'react';
import { TamaguiProvider } from 'tamagui';
import RootStack from './navigation';
import config from './tamagui.config';
SplashScreen.preventAutoHideAsync();
export default function App() {
const [loaded] = useFonts({
Inter: require('@tamagui/font-inter/otf/Inter-Medium.otf'),
InterBold: require('@tamagui/font-inter/otf/Inter-Bold.otf'),
});
useEffect(() => {
if (loaded) {
SplashScreen.hideAsync();
}
}, [loaded]);
if (!loaded) {
return null;
}
return (
<TamaguiProvider config={config}>
<RootStack />
</TamaguiProvider>
);
}