mirror of
https://github.com/facebook/docusaurus.git
synced 2025-08-02 08:19:07 +02:00
refactor: make MDX export a flat TOC list instead of tree (#6729)
This commit is contained in:
parent
2d93750caf
commit
c3370be64d
20 changed files with 312 additions and 445 deletions
|
@ -25,12 +25,6 @@ Once your website is bootstrapped, the website source will contain the Docusauru
|
|||
}
|
||||
```
|
||||
|
||||
## Index {#index}
|
||||
|
||||
import TOCInline from "@theme/TOCInline"
|
||||
|
||||
<TOCInline toc={toc[1].children}/>
|
||||
|
||||
## Docusaurus CLI commands {#docusaurus-cli-commands}
|
||||
|
||||
Below is a list of Docusaurus CLI commands and their usages:
|
||||
|
|
|
@ -17,7 +17,7 @@ However, it can be helpful if you have a high-level understanding of how the con
|
|||
|
||||
The high-level overview of Docusaurus configuration can be categorized into:
|
||||
|
||||
<TOCInline toc={toc[0].children} />
|
||||
<TOCInline toc={toc} minHeadingLevel={3} maxHeadingLevel={3} />
|
||||
|
||||
For exact reference to each of the configurable fields, you may refer to [**`docusaurus.config.js` API reference**](api/docusaurus.config.js.md).
|
||||
|
||||
|
|
|
@ -59,14 +59,6 @@ import TOCInline from '@theme/TOCInline';
|
|||
/>;
|
||||
```
|
||||
|
||||
```mdx-code-block
|
||||
<BrowserWindow>
|
||||
|
||||
<TOCInline toc={[toc[2], toc[4]]} />
|
||||
|
||||
</BrowserWindow>
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
:::caution
|
||||
|
|
|
@ -25,12 +25,6 @@ Once your website is bootstrapped, the website source will contain the Docusauru
|
|||
}
|
||||
```
|
||||
|
||||
## Index {#index}
|
||||
|
||||
import TOCInline from "@theme/TOCInline"
|
||||
|
||||
<TOCInline toc={toc[1].children}/>
|
||||
|
||||
## Docusaurus CLI commands {#docusaurus-cli-commands}
|
||||
|
||||
Below is a list of Docusaurus CLI commands and their usages:
|
||||
|
|
|
@ -17,7 +17,7 @@ However, it can be helpful if you have a high-level understanding of how the con
|
|||
|
||||
The high-level overview of Docusaurus configuration can be categorized into:
|
||||
|
||||
<TOCInline toc={toc[0].children} />
|
||||
<TOCInline toc={toc} minHeadingLevel={3} maxHeadingLevel={3} />
|
||||
|
||||
For exact reference to each of the configurable fields, you may refer to [**`docusaurus.config.js` API reference**](api/docusaurus.config.js.md).
|
||||
|
||||
|
|
|
@ -59,12 +59,6 @@ import TOCInline from '@theme/TOCInline';
|
|||
/>;
|
||||
```
|
||||
|
||||
```mdx-code-block
|
||||
<BrowserWindow>
|
||||
<TOCInline toc={[toc[2], toc[4]]} />
|
||||
</BrowserWindow>
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
:::caution
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue