import { useRouteError } from "@remix-run/react"
const Content = () => {
try {
const data = fetch("").then((res) => res.json())
} catch (error) {
throw new Response(error.message, { status: 500 });
}
}
export function ErrorBoundary() {
const error = useRouteError()
return <h1>Triggered: {error.message}</h1>
}
export default Content
This test snippet cause the whole server to crash with
code: 'ERR_INVALID_URL',
input: ''
}```