From a22416031de2badf19dafc9424d2d96339b2330e Mon Sep 17 00:00:00 2001 From: Samuel James Date: Sat, 5 Sep 2026 15:28:56 +0000 Subject: [PATCH] Clean up: Remove component files --- .../src/components/common/ErrorBoundary.tsx | 44 ------------------- 1 file changed, 44 deletions(-) delete mode 100644 frontend/src/components/common/ErrorBoundary.tsx diff --git a/frontend/src/components/common/ErrorBoundary.tsx b/frontend/src/components/common/ErrorBoundary.tsx deleted file mode 100644 index 44df331..0000000 --- a/frontend/src/components/common/ErrorBoundary.tsx +++ /dev/null @@ -1,44 +0,0 @@ -import React from 'react'; - -interface ErrorBoundaryState { - hasError: boolean; -} - -/** - * Last line of defence: a render crash shows a recovery screen instead of a - * blank page, so a user never loses sight of their work without an explanation. - */ -class ErrorBoundary extends React.Component<{ children: React.ReactNode }, ErrorBoundaryState> { - state: ErrorBoundaryState = { hasError: false }; - - static getDerivedStateFromError(): ErrorBoundaryState { - return { hasError: true }; - } - - componentDidCatch(error: Error, info: React.ErrorInfo): void { - // Kept in the console for now; a real logging endpoint is a Backend concern. - console.error('TaskFlow crashed while rendering', error, info.componentStack); - } - - render(): React.ReactNode { - if (this.state.hasError) { - return ( -
-

TaskFlow ran into a problem

-

Nothing was lost. Reload the page to pick up where you left off.

- -
- ); - } - - return this.props.children; - } -} - -export default ErrorBoundary;