Files
ragusaitweb/src/main.tsx
google-labs-jules[bot] 0591157e35 feat(security): add global error boundary for defense in depth
- Adds `ErrorBoundary` component to catch unhandled React exceptions
- Prevents UI crashes (White Screen of Death)
- Ensures stack traces are not leaked to the user (Security Enhancement)
- Wraps `App` in `main.tsx`
- Adds tests verifying fallback UI and absence of error details in DOM

Co-authored-by: ragusa-it <196988693+ragusa-it@users.noreply.github.com>
2026-02-06 02:00:05 +00:00

13 lines
308 B
TypeScript

import { StrictMode } from 'react';
import { createRoot } from 'react-dom/client';
import { App } from './App';
import { ErrorBoundary } from './components/layout';
createRoot(document.getElementById('root')!).render(
<StrictMode>
<ErrorBoundary>
<App />
</ErrorBoundary>
</StrictMode>
);