import React from 'react'; import { createRoot } from 'react-dom/client'; import App from './App.tsx'; import { ErrorBoundary } from './components/ui/ErrorBoundary.tsx'; const container = document.getElementById('root'); if (!container) { throw new Error('Root element not found. Ensure index.html has a
.'); } const root = createRoot(container); const renderApp = () => { try { root.render( ); } catch (error) { console.error('Fatal error during app render:', error); container.innerHTML = `

Fatal Error

The application failed to initialize.

Check the console for details.

`; } }; renderApp();