1
0
mirror of synced 2025-12-23 21:07:12 -05:00

Update to Mini TOCs guidance (#34196)

Co-authored-by: Laura Coursen <lecoursen@github.com>
This commit is contained in:
Andy Hudson
2023-01-27 08:21:09 +01:00
committed by GitHub
parent 325348efd6
commit 5a83e1b5d1

View File

@@ -192,12 +192,6 @@ featuredLinks:
- Type: `Boolean`. Default is `true` on articles, and `false` on map topics and `index.md` pages.
- Optional.
### `miniTocMaxHeadingLevel`
- Purpose: Indicates the maximum heading level to include in an article's mini TOC. See [Autogenerated mini TOCs](#autogenerated-mini-tocs) for more info.
- Type: `Number`. Default is `2`. Minimum is `2`. Maximum is `3`.
- Optional.
### `allowTitleToDifferFromFilename`
- Purpose: Indicates whether a page is allowed to have a title that differs from its filename. For example, `content/rest/reference/orgs.md` has a title of `Organizations` instead of `Orgs`. Pages with this frontmatter set to `true` will not be flagged in tests or updated by `script/reconcile-ids-with-filenames.js`.
@@ -286,10 +280,7 @@ As an alternative, you can change the single quotes surrounding the frontmatter
## Autogenerated mini TOCs
Every article on the help site displays an autogenerated "In this article" section (aka mini TOC) at the top of the page that includes links to all `H2`s in the article by default.
* To make the mini TOC include additional (or fewer) heading levels, you can add [`miniTocMaxHeadingLevel` frontmatter](#miniTocMaxHeadingLevel) to specify the maximum heading level. For example: `miniTocMaxHeadingLevel: 3`
* To disable the mini TOC for a specific article, you can add this frontmatter: [`showMiniToc: false`](#showMiniToc)
Every article on the help site displays an autogenerated "In this article" section (aka mini TOC) at the top of the page that includes links to all `H2`s in the article by default. Only H2 headers will be included in the mini TOCs.
Mini TOCs do not appear on product landing pages, category landing pages, or map topic pages.