React Bootstrap logoReact Bootstrap

DemoSection

文档

示例区块组件,用于在组件文档中展示可运行示例及其对应源代码

Component Demo

Basic usage and examples of the DemoSection component

基础用法

这是示例内容

查看代码

点击右上角「查看代码」切换代码展示

标题层级

三级标题

使用 level=3 呈现更小的三级标题

交互内容

计数:0

API Documentation

Complete API reference for the DemoSection component

Props

属性名类型默认值描述
childrenReactNode-示例预览区域的内容
classNamestring-自定义类名
codestring-示例代码(Markdown 或纯代码字符串)
codeLanguagestring'tsx'示例代码语言
idstring-示例区块锚点 id
levelTocLevel2标题层级(2 或 3)
titlestring-示例标题(必填)