内置组件
文件树

File Tree 组件

示例

    • _meta.json
    • contact.md
    • index.mdx
  • 用法

    import {FileTree} from 'nextra/components';
     
    <FileTree>
      <FileTree.Folder name='pages' defaultOpen>
        <FileTree.File name='_meta.json' />
        <FileTree.File name='contact.md' />
        <FileTree.File name='index.mdx' />
        <FileTree.Folder name='about'>
          <FileTree.File name='_meta.json' />
          <FileTree.File name='legal.md' />
          <FileTree.File name='index.mdx' />
        </FileTree.Folder>
      </FileTree.Folder>
    </FileTree>;