Markdown.AddToc

Description

This Task parses a Mardown file and adds a hyperlinked Table of Content containing all levels of headlines to the beginning of the file.

Markdown.AddToc only uses Regular Expressions and therefore has no external dependencies.

The Table of Contents will be seperated from the rest of the content by also adding ---, a horizonal rule.

Arguments

  • toc_header (optional) is a string of the headline to use for the added Table Of Contents.
# toc_header = '# Table of Contents'  # default
toc_header = '# Content'

Requirements

Python (Non-Standard-Library Packages)

None.

External Executables

None.

API Credentials

None.

Resources