-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathApp.tsx
50 lines (43 loc) · 1.42 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
47
48
49
50
/* eslint-disable import/no-mutable-exports */
/* eslint-disable @typescript-eslint/no-var-requires */
import './globalConfig';
import 'expo-dev-client';
import React from 'react';
import { StatusBar } from 'expo-status-bar';
import { View } from 'react-native';
import Toast from 'react-native-toast-message';
import QueryClientProvider from '@shared/provider/QueryClientProvider';
import FontThemeProvider from '@shared/provider/FontProvider';
import ReduxProvider from '@app/redux/Provider';
import RootNavigation from '@app/navigation/RootNavigation';
import isStorybookEnabled from '@shared/utils/isStorybookEnabled';
import { fullScreenContainer } from '@shared/constants/style';
import { toastConfig } from '@shared/components/toastMessage/Config';
export function App() {
return (
<View style={fullScreenContainer}>
<StatusBar style="dark" animated />
<QueryClientProvider>
<ReduxProvider>
<FontThemeProvider>
<RootNavigation />
</FontThemeProvider>
</ReduxProvider>
</QueryClientProvider>
<Toast
visibilityTime={6000}
onPress={() => Toast.hide()}
config={toastConfig}
/>
</View>
);
}
let AppEntryPoint = App;
/**
* Hide/Show storybook
* @see docs https://github.com/storybookjs/react-native#hideshow-storybook
*/
if (isStorybookEnabled()) {
AppEntryPoint = require('./.storybook').default;
}
export default AppEntryPoint;