Enable exception reporting & default error screen to report GitHub bug (#82)

This commit is contained in:
Will Chen
2025-05-05 14:19:33 -07:00
committed by GitHub
parent ac8ef73bee
commit 43cf62a93c
4 changed files with 123 additions and 0 deletions

View File

@@ -16,6 +16,7 @@ const routeTree = rootRoute.addChildren([
// src/components/NotFoundRedirect.tsx
import * as React from "react";
import { useNavigate } from "@tanstack/react-router";
import { ErrorBoundary } from "./components/ErrorBoundary";
export function NotFoundRedirect() {
const navigate = useNavigate();
@@ -35,6 +36,7 @@ export function NotFoundRedirect() {
export const router = createRouter({
routeTree,
defaultNotFoundComponent: NotFoundRedirect,
defaultErrorComponent: ErrorBoundary,
});
declare module "@tanstack/react-router" {