Component docs
Loading
import { AppMain } from "@pixxl-tools/components";
// In Server Components:
import { AppMain } from "@pixxl-tools/components/server";| Prop | Type | Default | Description |
|---|---|---|---|
as | "div" | "main" | main | main (default) is the page's main landmark. Use div when the app is not the page's main content — a preview or demo inside a page that already has a <main> (one main landmark per page). |
skipTarget | boolean | — | Skip-link target: id="main" (unless id is set) and tabIndex={-1}, so SiteHeader's "Skip to content" lands here without a focus ring around the page. Default true for as="main", false for div. |
asdefault main"div" | "main"
main (default) is the page's main landmark. Use div when the app is not the page's main content — a preview or demo inside a page that already has a <main> (one main landmark per page).
skipTargetboolean
Skip-link target: id="main" (unless id is set) and tabIndex={-1}, so SiteHeader's "Skip to content" lands here without a focus ring around the page. Default true for as="main", false for div.
Other props are passed to the root element (HTMLAttributes<HTMLElement>), including className, style, id and aria-* attributes.
<AppMain>...</AppMain>