import type { FunctionComponent, ReactNode } from "react"; import type { LinksFunction } from "@remix-run/node"; import { Link, Links, LiveReload, Meta, Outlet, Scripts, ScrollRestoration, useCatch } from "@remix-run/react"; import Logo from "~/features/core/components/logo"; import styles from "./styles/tailwind.css"; export const links: LinksFunction = () => [ { rel: "stylesheet", href: styles }, { rel: "icon", href: "/favicon.ico", }, { rel: "apple-touch-icon", sizes: "180x180", href: "/apple-touch-icon.png", }, { rel: "icon", type: "image/png", sizes: "32x32", href: "/favicon-32x32.png", }, { rel: "icon", type: "image/png", sizes: "16x16", href: "/favicon-16x16.png", }, { rel: "mask-icon", href: "/safari-pinned-tab.svg", color: "#663399", }, ]; export default function App() { return ( ); } // https://remix.run/docs/en/v1/api/conventions#errorboundary export function ErrorBoundary({ error }: { error: Error }) { console.error(error); return (

There was an error

{error.message}

); } // https://remix.run/docs/en/v1/api/conventions#catchboundary export function CatchBoundary() { const caught = useCatch(); let message; switch (caught.status) { case 401: message =

Oops! Looks like you tried to visit a page that you do not have access to.

; break; case 404: message =

Oops! Looks like you tried to visit a page that does not exist.

; break; default: throw new Error(caught.data || caught.statusText); } return (

{caught.status}: {caught.statusText}

{message}
); } const Document: FunctionComponent<{ children: ReactNode }> = ({ children }) => ( {children} );