AppProvider API
API reference docs for the React AppProvider component. Learn about the props, CSS, and other APIs of this exported module.
Demos
Import
import { AppProvider } from '@toolpad-core/AppProvider';
import { AppProvider } from '@toolpad-core/nextjs/AppProvider'; // Next.js
// or
import { AppProvider } from '@toolpad-core';
import { AppProvider } from '@toolpad-core/nextjs'; // Next.js
Learn about the difference by reading this guide on minimizing bundle size.
Props of the native component are also available.
Name | Type | Default | Description |
---|---|---|---|
children* | node | - | The content of the app provider. |
branding | { logo?: node, title?: string } | null | Branding options for the app. |
navigation | Array<{ children?: Array<object | { kind: 'header', title: string } | { kind: 'divider' }>, icon?: node, kind?: 'page', slug?: string, title: string } | { kind: 'header', title: string } | { kind: 'divider' }> | [] | Navigation definition for the app. |
router | { navigate: func, pathname: string, searchParams?: URLSearchParams } | null | Router implementation used inside Toolpad components. |
theme | object | baseTheme | Theme used by the app. |
The component cannot hold a ref.