diff options
author | Bjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com> | 2015-08-07 20:09:40 +0200 |
---|---|---|
committer | Bjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com> | 2015-08-07 20:09:40 +0200 |
commit | b05a292c218aeb1e21fc5fee2e94437b09cb977b (patch) | |
tree | 9e74a32d4e4595db22b459c12c12061d48cabf07 /helpers/content.go | |
parent | 0f1fb8c7d8e404fc8e395fc7e8e751dfa7af8bb6 (diff) |
Revert "Fix some Go code doc issues"
This reverts commit de7dd70bbc1ac533f137e5f788e1b337d6ba6b8c.
Broke the code fence feat.
Diffstat (limited to 'helpers/content.go')
-rw-r--r-- | helpers/content.go | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/helpers/content.go b/helpers/content.go index 11e2755d3..8e3fda505 100644 --- a/helpers/content.go +++ b/helpers/content.go @@ -134,7 +134,7 @@ func BytesToHTML(b []byte) template.HTML { return template.HTML(string(b)) } -// GetHTMLRenderer creates a new Blackfriday Renderer with the given configuration. +// GetHtmlRenderer creates a new Renderer with the given configuration. func GetHTMLRenderer(defaultFlags int, ctx *RenderingContext) blackfriday.Renderer { renderParameters := blackfriday.HtmlRendererParameters{ FootnoteAnchorPrefix: viper.GetString("FootnoteAnchorPrefix"), @@ -172,11 +172,12 @@ func GetHTMLRenderer(defaultFlags int, ctx *RenderingContext) blackfriday.Render htmlFlags |= blackfriday.HTML_SMARTYPANTS_LATEX_DASHES } - return &hugoHtmlRenderer{ + return &HugoHtmlRenderer{ blackfriday.HtmlRendererWithParameters(htmlFlags, "", "", renderParameters), } } + func getMarkdownExtensions(ctx *RenderingContext) int { flags := 0 | blackfriday.EXTENSION_NO_INTRA_EMPHASIS | blackfriday.EXTENSION_TABLES | blackfriday.EXTENSION_FENCED_CODE | @@ -208,7 +209,7 @@ func markdownRenderWithTOC(ctx *RenderingContext) []byte { getMarkdownExtensions(ctx)) } -// GetMmarkHtmlRenderer creates a new MMark Renderer with the given configuration. +// mmark func GetMmarkHtmlRenderer(defaultFlags int, ctx *RenderingContext) mmark.Renderer { renderParameters := mmark.HtmlRendererParameters{ FootnoteAnchorPrefix: viper.GetString("FootnoteAnchorPrefix"), @@ -219,6 +220,7 @@ func GetMmarkHtmlRenderer(defaultFlags int, ctx *RenderingContext) mmark.Rendere if b && !ctx.getConfig().PlainIDAnchors { renderParameters.FootnoteAnchorPrefix = ctx.DocumentID + ":" + renderParameters.FootnoteAnchorPrefix + // renderParameters.HeaderIDSuffix = ":" + ctx.DocumentId } htmlFlags := defaultFlags |