0

TOC for Markdown

David Loeffler 7 years ago updated 7 years ago 2

If I use --- or === then the header does not show up in the TOC, but the headers I start with # do.  For Markdown the headers underlined with dashes or equal signs should be included in the TOC.

Unfortunately that's a limitation of the syntax highlighter. It only ever looks at one line at a time. So in the case of "---" it would have to mark the previous line as a headline. That's not supported by TextMate's syntax definitions.


I recommend to use "#" for headlines.

The good thing is Multimarkdown Composer 2 and Marked both handle the TOC issue with --- and === markers. I know, Marked is just a viewer but the best IMHO.