Insert Table of Contents
Release 3.2.0+, Release 2.20.0+
Extracts headings (H1–H6) from the document and inserts a Table of Contents at the caret position. The TOC structure follows the heading hierarchy.
Add the toolbar button:
// synapeditor.config.js
{
'editor.toolbar': [
// ...
'tableOfContents'
// ...
]
}

Extract Specific Headings (Custom Styles)
Customize the className and style of each heading with editor.titleStyle. When a paragraph carries a class registered here, it is recognized as a heading element during TOC extraction.
Supported paragraph elements:
<h1>, <h2>, <h3>, <h4>, <h5>, <h6>, <p>
<div class="se-para-div">...</div>
See: Heading H1-H6 Class & Style Customization
