feat(web): add React error boundaries and Next.js error.tsx fallbacks
Runtime errors in components now show a friendly "Something went wrong" screen instead of a white page. Timeline and staffing panel are individually wrapped. Route-level error.tsx handles server component errors. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
import dynamic from "next/dynamic";
|
||||
import { ErrorBoundary } from "~/components/ui/ErrorBoundary.js";
|
||||
|
||||
const TimelineView = dynamic(
|
||||
() => import("~/components/timeline/TimelineView.js").then((m) => m.TimelineView),
|
||||
@@ -22,7 +23,9 @@ export default function TimelinePage() {
|
||||
<p className="app-page-subtitle mt-1">Interactive resource planning timeline</p>
|
||||
</div>
|
||||
</div>
|
||||
<TimelineView />
|
||||
<ErrorBoundary>
|
||||
<TimelineView />
|
||||
</ErrorBoundary>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user