Tabs #
TabPanels renders a tab group. Each Tab child represents one tab, with its title displayed as the tab button label. Tab content can be any HTML or Markdown.
Props #
TabPanels #
| Prop | Type | Required | Description |
|---|---|---|---|
children | Tab elements | Yes | One or more Tab components. |
Tab #
| Prop | Type | Required | Description |
|---|---|---|---|
title | string | Yes | Label shown on the tab button. |
children | ReactNode | Yes | Content rendered when the tab is active. |
Live examples #
npm run dev
Markdown + MDX content pages.
Code #
mdx
<TabPanels><Tab title="JavaScript">npm run dev</Tab><Tab title="pnpm">pnpm dev</Tab><Tab title="Bun">bun run dev</Tab></TabPanels>