import { useRouteError } from "react-router-dom"; export default function ErrorPage() { const error = useRouteError() console.error(error) return (
Sorry, an unexpected error has occurred.
{error.statusText || error.message}