Components
menu-provider
Code

MenuProvider

MenuProvider<T>(props): ReactElement

Provides a menu store to Menu components.

Type parameters

NameType
Textends MenuStoreValues = MenuStoreValues

Parameters

NameType
propsPickRequired<MenuProviderProps<T>, "values" | "defaultValues">

Returns

ReactElement

See

https://ariakit.org/components/menu (opens in a new tab)

Example

<MenuProvider placement="top">
  <MenuButton>Edit</MenuButton>
  <Menu>
    <MenuItem>Undo</MenuItem>
    <MenuItem>Redo</MenuItem>
  </Menu>
</MenuProvider>

Defined in

node_modules/.pnpm/@ariakit+react-core@0.3.5_react-dom@18.2.0_react@18.2.0/node_modules/@ariakit/react-core/cjs/menu/menu-provider.d.ts:19

MenuProvider(props?): ReactElement

Parameters

NameType
props?MenuProviderProps<MenuStoreValues>

Returns

ReactElement

Defined in

node_modules/.pnpm/@ariakit+react-core@0.3.5_react-dom@18.2.0_react@18.2.0/node_modules/@ariakit/react-core/cjs/menu/menu-provider.d.ts:20