Documentation
FileTree

File Tree Component

Example

    • _meta.json
    • contact.md
    • index.mdx
  • Usage

    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>