Skip to content
  • System
  • Light
  • Dark
  • High contrast

SkipLink

Renders a link pointing to #main-content with the label “Skip to main content”. Normally hidden — only visible on keyboard focus. Forced visible here for demonstration.

Skip to main content
import { SkipLink } from '@eekodigital/raster';

<SkipLink />

Visually hidden until focused. In production, the SkipLink is positioned off-screen and only becomes visible when a keyboard user tabs to it — the very first focusable element on the page.

Override the default target anchor when your main landmark uses a different id.

<SkipLink href="#content" />

Pass children to replace the default link text.

<SkipLink>Skip to content</SkipLink>

Always render SkipLink as the first child of <body> (or the first element inside your app root) so it is the first tab stop on every page.

PropTypeDefaultDescription
hrefstring'#main-content'The anchor target to jump to when activated.
childrenReactNode'Skip to main content'Link label text.
...propsAnchorHTMLAttributesAll native anchor attributes.