-
Notifications
You must be signed in to change notification settings - Fork 0
/
App.js
71 lines (57 loc) · 2.1 KB
/
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
import {ImageBackground, LogBox} from 'react-native';
import {getApp, initializeApp} from 'firebase/app';
import firebaseConfig from './src/firebase/firebaseConfig';
import Home from "./src/navigation/navigation";
import Loading_Screen from './loading';
import './ i18n';
import {SheetProvider} from "react-native-actions-sheet";
import './src/components/Sheets';
import {
useFonts,
OpenSans_300Light,
OpenSans_400Regular,
OpenSans_500Medium,
OpenSans_600SemiBold,
OpenSans_700Bold,
OpenSans_800ExtraBold,
OpenSans_300Light_Italic,
OpenSans_400Regular_Italic,
OpenSans_500Medium_Italic,
OpenSans_600SemiBold_Italic,
OpenSans_700Bold_Italic,
OpenSans_800ExtraBold_Italic,
} from '@expo-google-fonts/open-sans';
import MythContextProvider from "./store/myth-context";
import BleContextProvider from "./store/ble-context";
try {
initializeApp(firebaseConfig);
} catch (err) {
// we skip the “already exists” message which is
// not an actual error when we’re hot-reloading
if (!getApp.length) {
console.error("Firebase initialization error raised", err.stack);
}
}
const app = initializeApp(firebaseConfig)
// LogBox.ignoreAllLogs(true)
LogBox.ignoreLogs([
"expo-app-loading is deprecated in favor of expo-splash-screen"
]);
export default function App() {
let [fontsLoaded] = useFonts({
OpenSans_300Light, OpenSans_400Regular, OpenSans_500Medium, OpenSans_600SemiBold, OpenSans_700Bold, OpenSans_800ExtraBold, OpenSans_300Light_Italic, OpenSans_400Regular_Italic, OpenSans_500Medium_Italic, OpenSans_600SemiBold_Italic, OpenSans_700Bold_Italic, OpenSans_800ExtraBold_Italic,
});
if (!fontsLoaded) {
return < Loading_Screen/>;
} else {
return (
<BleContextProvider>
<SheetProvider>
<MythContextProvider>
<Home/>
</MythContextProvider>
</SheetProvider>
</BleContextProvider>
);
}
}