|
import React from 'react';
|
|
import ReactDOM from 'react-dom/client';
|
|
import { BrowserRouter } from 'react-router-dom';
|
|
import { QueryClient, QueryClientProvider } from 'react-query';
|
|
import { Toaster } from 'react-hot-toast';
|
|
import App from './App';
|
|
import './styles/globals.css';
|
|
|
|
const queryClient = new QueryClient({
|
|
defaultOptions: {
|
|
queries: {
|
|
retry: 1,
|
|
refetchOnWindowFocus: false,
|
|
},
|
|
},
|
|
});
|
|
|
|
const root = ReactDOM.createRoot(document.getElementById('root'));
|
|
root.render(
|
|
<React.StrictMode>
|
|
<QueryClientProvider client={queryClient}>
|
|
<BrowserRouter>
|
|
<App />
|
|
<Toaster
|
|
position="top-right"
|
|
toastOptions={{
|
|
style: {
|
|
background: '#1a1a1a',
|
|
color: '#ffffff',
|
|
border: '1px solid #333',
|
|
},
|
|
}}
|
|
/>
|
|
</BrowserRouter>
|
|
</QueryClientProvider>
|
|
</React.StrictMode>
|
|
); |