Repository navigation
feat: 404 and error pages as inkan answers them - #10
Merged
Merged
Conversation
A problem+json card with the address asked for, the stamp, search and the ways back. error.tsx keeps the nav and offers a retry; global-error.tsx stands on its own.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Own pages for everything that goes wrong, instead of Next's defaults.
app/not-found.tsx, also whatnotFound()in the docs shows): "No route for this one.", the seal stamped on with a small spring, and on the right the answer an inkan app would give, asapplication/problem+jsonwith the address that was asked for. Below: search the docs (opens the ⌘K dialog), and Docs, Hanko, Blog, Home. Still answers with status 404,noindex.app/error.tsx): the same layout with nav and footer, "Try again" (reset()), and the digest in the problem so an issue can point at the log.app/global-error.tsx): no providers there, so no nav and no search, the rest the same.components/problem-page.tsxholds the shared part.Checked in the browser on the dev server:
/gibt-es-nichtand/docs/does-not-existanswer 404 with the page, desktop dark and mobile light. Typecheck and lint pass.