-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathApp.tsx
46 lines (38 loc) · 1.12 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
/**
* Sample React Native App
* https://github.com/facebook/react-native
*
* @format
*/
import React from 'react';
import {StatusBar} from 'react-native';
import {Provider} from 'react-redux';
import {ApolloProvider} from '@apollo/client';
import Toast from 'react-native-toast-message';
import {PersistGate} from 'redux-persist/integration/react';
// store
import {store, persistor} from './src/store';
// routes
import Layout from './src/routes';
// gql
import client from './src/graphql/ApolloClient';
// contexts
import {ActivityIndicatorProvider} from './src/contexts/ActivityIndicator';
// utils
import {toastConfig} from './src/utils/toast';
function App(): React.JSX.Element {
return (
<Provider store={store}>
<PersistGate loading={null} persistor={persistor}>
<StatusBar barStyle={'light-content'} backgroundColor={'#000'} />
<ApolloProvider client={client}>
<ActivityIndicatorProvider>
<Layout />
<Toast config={toastConfig} />
</ActivityIndicatorProvider>
</ApolloProvider>
</PersistGate>
</Provider>
);
}
export default App;