Sidebar

The navigation bar at aside of viewport

A sidebar component which handles device resizing and remove scroll bar automatically.

Usage

import * as Base from 'fumadocs-core/sidebar';
 
return (
  <Base.SidebarProvider>
    <Base.SidebarTrigger />
    <Base.SidebarList />
  </Base.SidebarProvider>
);
PropTypeDefault
open
boolean
-
onOpenChange
(v: boolean) => void
-
children
ReactNode
-

Opens the sidebar on click.

PropTypeDefault
as
ElementType
-
Data AttributeValuesDescription
data-opentrue, falseIs sidebar opening
Edit on GitHub

Last updated on

On this page