Logo产品教程
Logo产品教程
首页

介绍

快速入门
什么是 Fumadocs对比

设置

手动安装静态导出

写作

Markdown国际化

UI

概览主题搜索
组件
MDX

标题

MDX 文档的标题组件

Hello World

Hello World Everyone!

自动添加 id 属性的标题组件。

使用方法

将其添加到您的 MDX 组件中,从 h1 到 h6。

import { Heading } from 'fumadocs-ui/components/heading';

<MDX
  components={{
    h1: (props) => <Heading as="h1" {...props} />,
    h2: (props) => <Heading as="h2" {...props} />,
    h3: (props) => <Heading as="h3" {...props} />,
    h4: (props) => <Heading as="h4" {...props} />,
    h5: (props) => <Heading as="h5" {...props} />,
    h6: (props) => <Heading as="h6" {...props} />,
  }}
/>

目录

使用方法