-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathApp.js
More file actions
35 lines (34 loc) · 1.11 KB
/
App.js
File metadata and controls
35 lines (34 loc) · 1.11 KB
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
import "react-native-gesture-handler";
import { StatusBar } from "expo-status-bar";
import React, { useState, useEffect } from "react";
import { Platform, SafeAreaView, View } from "react-native";
import { _loadResourcesAsync } from "utils/loadFonts";
import {Provider as Paperprovider} from 'react-native-paper';
import { useTheme } from "react-native-paper";
import { NavigationContainer } from '@react-navigation/native';
import { linking } from 'utils/linking';
import AppStack from 'navigation/AppStack';
import Realm from './src/Realm'
export default function App() {
const [isFontLoaded, setFontLoaded] = useState(false);
const {theme} = useTheme()
useEffect(() => {
_loadResourcesAsync().then(() => {
setFontLoaded(true);
});
}, []);
console.log(Realm)
if (!isFontLoaded) {
return <View></View>;
}
return (
<Paperprovider theme={theme}>
<SafeAreaView style={{ flex: 1 }}>
{Platform.OS === "ios" && <StatusBar style="dark" />}
<NavigationContainer linking={linking}>
<AppStack />
</NavigationContainer>
</SafeAreaView>
</Paperprovider>
);
};