Table of contents
waylan at gmail.com
Thu Mar 5 09:02:09 EST 2009
On Thu, Mar 5, 2009 at 4:27 AM, Daniel Winterstein
<daniel.winterstein at gmail.com> wrote:
> I'm using Markdown in an app and would like to provide support for including
> a table of contents.
> Any suggestions for a syntax? Has anyone done this before?
Yes, Python-Markdown has an extension  that does this.
Unfortunately, its not documented properly yet (it hasn't been
officially released yet either), but it works on the same basic
premise as your third suggestion. It uses all the headers to build a
nested list and then either inserts that list at the location of the
marker ``[TOC]``, or if the marker is not found, at the beginning of
\X/ /-\ `/ |_ /-\ |\|
More information about the Markdown-Discuss