import React from 'react';
import ReactDOM from 'react-dom/client';
import App from './App';
import './styles.css';

export function mountReactApp(): void {
  const container = document.getElementById('app');

  if (!container) {
    throw new Error('Missing #app container for React entry.');
  }

  ReactDOM.createRoot(container).render(
    <React.StrictMode>
      <App />
    </React.StrictMode>,
  );
}
