Changes in Markdown Preview Sublime Text 2 Plugin

Changes in Markdown Preview Sublime Text 2 Plugin

to support [TOC] in body for Table of content (enclosed in DIV id=“toc”)

Path is: %SystemDrive% cd %APPDATA%\Sublime Text 2\Packages\Markdown Preview\

File is: MarkdownPreview.py

        # convert the markdown
        markdown_html = markdown2.markdown(contents, extras=['footnotes', 'toc', 'fenced-code-blocks', 'cuddled-lists', 'code-friendly'])

*** toc_html = getattr(markdown_html, “toc_html”) # postprocess the html markdown_html = self.postprocessor(markdown_html)

    html_contents += '</head><body>'

*** html_contents += markdown_html.replace("[[TOC]]", “\n

\n” + toc_html + “
\n”, 1) html_contents += ‘’

date 01. Jan 0001 | modified 28. May 2021
filename: Markdown Preview Plugin Change