import 'react-native-gesture-handler';
import React, { useEffect } from 'react';
import { Provider } from 'react-redux';
import { NavigationContainer } from '@react-navigation/native';
import { useColorScheme } from 'react-native';
import RNBootSplash from 'react-native-bootsplash';
import { enableScreens } from 'react-native-screens';
import { store, persistor } from 'store';
import Navigation from 'components/navigation';
import { ColorScheme, DarkTheme, LightTheme } from 'helpers/Themes';
import { DefaultTheme, Provider as PaperProvider } from 'react-native-paper';
//import { theme } from 'src/core/theme.js';

enableScreens();
export const theme = {
  ...DefaultTheme,
  colors: {
    ...DefaultTheme.colors,
    primary: '#600EE6',
    secondary: '#414757',
    error: '#f13a59',
  },
};
function App() {
  const scheme = useColorScheme();

  useEffect(() => {
    persistor(RNBootSplash.hide);
  }, []);

  return (

    <Provider store={store}>
      <PaperProvider theme={theme}>
      <NavigationContainer
        
      >
        <Navigation />
      </NavigationContainer>
      </PaperProvider>
    </Provider>
  );
}

export default App;
