💠An Obsidian plugin to create a table of contents in a note, that updates itself when the note changes
MIT License
An Obsidian plugin to create a table of contents in a note, that updates itself when the note changes
Install the plugin from the Community plugins section in the app settings.
Clone the plugin in your .obsidian/plugins
directory:
cd /path/to/your/vault/.obsidian/plugins
git clone [email protected]:johansatge/obsidian-automatic-table-of-contents.git
Download the latest release and unzip it in the .obsidian/plugins/automatic-table-of-contents
directory.
Insert a codeblock with the table-of-contents
(or its short version toc
) syntax.
```table-of-contents
option1: value1
option2: value2
```
Alternatively, two commands are available in the command palette:
The following options are available:
Option | Default value | Description |
---|---|---|
title |
None | Title to display before the table of contents (supports Markdown) |
style |
nestedList |
Table of contents style (can be nestedList , nestedOrderedList or inlineFirstLevel ) |
minLevel |
0 |
Include headings from the specified level (0 for no limit) |
maxLevel |
0 |
Include headings up to the specified level (0 for no limit) |
includeLinks |
true |
Make headings clickable |
debugInConsole |
false |
Print debug info in Obsidian console |
includeLinks: true
(see #24 & #27)includeLinks: true
(see #13)README.md
manifest.json
README.md
as descriptionmain.js
and manifest.json
as attachmentsThis project uses semver.
Version | Date | Notes |
---|---|---|
1.4.0 |
2024-05-19 | Add nestedOrderedList style (@bjtho08) (fix #41) |
1.3.3 |
2024-05-16 | Compute the right min level when style:inlineFirstLevel (fix #39) |
1.3.2 |
2024-02-18 | Harden headings stripping |
1.3.1 |
2024-02-18 | Strip headings for readability (fix #24, #27) |
1.3.0 |
2024-02-17 | Introduce title option (fix #5, #32) |
1.2.0 |
2024-01-19 | Introduce toc shorthand trigger (fix #19) |
1.1.0 |
2024-01-03 | Introduce minLevel option (@ras0q) (fix #11) |
1.0.6 |
2023-11-02 | Escape special characters (fix #3) |
1.0.5 |
2023-11-01 | Fix plugin activation on mobile (fix #17) |
1.0.4 |
2023-10-31 | Support pages with no first level headings (fix #6) |
1.0.3 |
2023-09-30 | Fix readme |
1.0.2 |
2023-09-25 | Fix output sometimes displaying undefined headings |
1.0.1 |
2023-09-09 | Fix reference to global App instance |
1.0.0 |
2023-08-27 | Initial version |
This project is released under the MIT License.
Bug reports and feature requests are welcome! More details in the contribution guidelines.