Files
ohome-app/App.js
2021-11-02 13:45:29 +01:00

52 lines
1.1 KiB
JavaScript

import React from 'react';
// import 'bootstrap/dist/css/bootstrap.min.css';
import { useFonts } from 'expo-font';
import App from './src/App';
// //styles
import { ThemeProvider } from 'styled-components'
// import GlobalStyle from './src/styles/globalStyles'
import Theme from './src/styles/theme'
// //redux
import { Provider } from 'react-redux'
import store from './src/redux/store';
import { fetchAll } from './src/utils'
import { StatusBar } from 'expo-status-bar';
import { StyleSheet, View } from 'react-native';
fetchAll()
export default function Index() {
let [fontsLoaded] = useFonts({
'sansation_light': require('./assets/fonts/sansation_light.ttf'),
'sansation_regular': require('./assets/fonts/sansation_regular.ttf'),
});
if (!fontsLoaded) {
return <View/>;
}
else {
return (
<View style={styles.container}>
<Provider store={store}>
<ThemeProvider theme={Theme}>
{/* <GlobalStyle /> */}
<App />
<StatusBar style="auto" />
</ThemeProvider>
</Provider>
</View>
);
}
}
const styles = StyleSheet.create({
container: {
flex: 1,
backgroundColor: '#fff',
},
});