-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathApp.tsx
32 lines (29 loc) · 1.11 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
import { StatusBar } from 'expo-status-bar';
import { SafeAreaProvider } from 'react-native-safe-area-context';
import * as React from 'react';
import { ThemeProvider } from 'react-native-elements';
import { QueryClient, QueryClientProvider } from 'react-query';
import { NavigationContainer } from '@react-navigation/native';
import { UserContext } from './ts/CommonContext/UserContext';
import { useState } from 'react';
import { createBottomTabNavigator } from '@react-navigation/bottom-tabs';
import AppStack from './ts/Common/components/AppStack';
const queryClient = new QueryClient();
export default function App() {
const [user, setUser] = useState({});
const userContextValue = { user, setUser };
return (
<NavigationContainer>
<UserContext.Provider value={userContextValue}>
<SafeAreaProvider>
<ThemeProvider>
<StatusBar style="light" />
<QueryClientProvider client={queryClient}>
<AppStack />
</QueryClientProvider>
</ThemeProvider>
</SafeAreaProvider>
</UserContext.Provider>
</NavigationContainer>
);
}