import { useRouteError } from "react-router-dom"; export function ErrorBoundary() { const error = useRouteError() as any; return (