2021-07-01 09:05:26 +02:00
---
title: ToC-Tree
---
2020-06-07 17:42:03 +02:00
The `toc-tree` shortcode will generate a Table of Content from a section file tree of your content directory. The root of the resulting ToC will be the page on which you define the shortcode.
2020-02-16 23:39:23 +01:00
2023-10-27 21:38:23 +02:00
## Usage
2022-01-06 13:58:10 +01:00
<!-- prettier - ignore - start -->
2020-02-16 23:39:23 +01:00
```tpl
2024-01-12 11:56:06 +01:00
{{< /* toc-tree [sortBy="title"] */>}}
2020-02-16 23:39:23 +01:00
```
2022-01-06 13:58:10 +01:00
<!-- prettier - ignore - end -->
2020-02-16 23:39:23 +01:00
2024-01-12 11:56:06 +01:00
### Attributes
<!-- prettier - ignore - start -->
<!-- spellchecker - disable -->
{{< propertylist name = shortcode-toc-tree sort = name order = asc > }}
<!-- spellchecker - enable -->
<!-- prettier - ignore - end -->
2020-02-16 23:39:23 +01:00
## Example
2021-01-03 22:48:34 +01:00
As said, the root will be the site on which the shortcode was used, you can see a demo including nesting in the [ToC Tree ](/toc-tree/ ) section.