Enable header id blackfriday extension
authorDave Johnston <johnsto@gmail.com>
Sat, 30 Aug 2014 08:25:20 +0000 (08:25 +0000)
committerspf13 <steve.francia@gmail.com>
Sat, 30 Aug 2014 18:12:53 +0000 (14:12 -0400)
hugolib/page.go

index a538fc5b1d30cc828f9d478f4ec7bef9f37669d9..202c8042e467c59eea947f12159cc603a95ffa3b 100644 (file)
@@ -684,6 +684,7 @@ func markdownRender(content []byte) []byte {
        extensions |= blackfriday.EXTENSION_STRIKETHROUGH
        extensions |= blackfriday.EXTENSION_SPACE_HEADERS
        extensions |= blackfriday.EXTENSION_FOOTNOTES
+       extensions |= blackfriday.EXTENSION_HEADER_IDS
 
        return blackfriday.Markdown(content, renderer, extensions)
 }
@@ -706,6 +707,7 @@ func markdownRenderWithTOC(content []byte) []byte {
        extensions |= blackfriday.EXTENSION_STRIKETHROUGH
        extensions |= blackfriday.EXTENSION_SPACE_HEADERS
        extensions |= blackfriday.EXTENSION_FOOTNOTES
+       extensions |= blackfriday.EXTENSION_HEADER_IDS
 
        return blackfriday.Markdown(content, renderer, extensions)
 }