|
|
import React from 'react'; |
|
|
import ReactDOM from 'react-dom/client'; |
|
|
import './index.css'; |
|
|
import App from './app/App.tsx'; |
|
|
import ErrorBoundary from './app/components/common/ErrorBoundary.tsx'; |
|
|
import reportWebVitals from './reportWebVitals'; |
|
|
|
|
|
|
|
|
const storedTheme = localStorage.getItem('app-theme') || 'dark'; |
|
|
if (storedTheme === 'dark') { |
|
|
document.documentElement.classList.add('dark'); |
|
|
} else { |
|
|
document.documentElement.classList.remove('dark'); |
|
|
} |
|
|
|
|
|
const root = ReactDOM.createRoot(document.getElementById('root')); |
|
|
root.render( |
|
|
<React.StrictMode> |
|
|
<ErrorBoundary> |
|
|
<App /> |
|
|
</ErrorBoundary> |
|
|
</React.StrictMode> |
|
|
); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
reportWebVitals(); |
|
|
|