跳转到内容

TabContext API

想要学习更多组件属性和 CSS API,可以查阅 React TabContext 组件的 API 文档。

演示项目

For examples and details on the usage of this React component, visit the component demo pages:

导入

import TabContext from '@mui/lab/TabContext';
// 或
import { TabContext } from '@mui/lab';
你可以阅读这个关于最小化捆绑包的指南以了解以上二者的差异。

属性

原生(Native) 组件的属性也是可用的。

名称类型默认值描述
value*string
The value of the currently selected Tab.
childrennode
The content of the component.

组件无法持有 ref。