Skip to content

Feedback

ErrorState

A page that could not be shown.

Examples

not found

Page not found

The page you're looking for has moved, or never existed.

Back home

Notes

A page that could not be shown.

The code is set at the top of the type ladder and marked aria-hidden — read aloud, "404" before the sentence explaining it is noise, and the heading immediately after says the same thing in words.

Props

ErrorState props
PropTypeDefaultDescription
actionrequiredReactNodeThe way back. Render it with .
coderequiredReactNodeThe status, set large — "404", "500". Decorative; the heading carries the meaning.
headingrequiredReactNode
messagerequiredReactNode

Also accepts everything in HTMLAttributes<HTMLElement>. Those are forwarded to the underlying element and are not listed row by row.

Re-exports

ERROR_ACTION_CLASS = 'text-sm text-(--ink) underline decoration-(--rule-2) underline-offset-4 transition-colors duration-(--duration-fast) hover:decoration-(--ink)'

The recovery affordance's look, exported so every error page offers the same one rather than each inventing a link style.

Accessibility

  • The big status code is aria-hidden; the heading immediately after says the same thing in words.