Skip to content

Commit

Permalink
feat(not-found.tsx): add NotFound component, this might allow next.js…
Browse files Browse the repository at this point in the history
… to skip a whole renderer process at runtime, because at the moment the 404 page is recognized as a pages app
  • Loading branch information
masterkain committed Jul 22, 2023
1 parent 9167ca6 commit 98a2a1c
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions app/not-found.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
export default function NotFound() {
return (
<>
<main className="grid min-h-full place-items-center bg-white px-6 py-24 sm:py-32 lg:px-8">
<div className="text-center">
<p className="text-base font-semibold text-indigo-600">404</p>
<h1 className="mt-4 text-3xl font-bold tracking-tight text-gray-900 sm:text-5xl">Page not found</h1>
<p className="mt-6 text-base leading-7 text-gray-600">Sorry, we couldn’t find the page you’re looking for.</p>
<div className="mt-10 flex items-center justify-center gap-x-6">
<a
href="/"
className="rounded-md bg-indigo-600 px-3.5 py-2.5 text-sm font-semibold text-white shadow-sm hover:bg-indigo-500 focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-indigo-600"
>
Go back home
</a>
</div>
</div>
</main>
</>
);
}

0 comments on commit 98a2a1c

Please sign in to comment.