mirror of
https://github.com/gohugoio/hugo.git
synced 2024-11-21 20:46:30 -05:00
Simplify the configuration of HugoHTMLRenderer
This commit is contained in:
parent
4d4da001a0
commit
91b61b976d
2 changed files with 3 additions and 5 deletions
|
@ -203,9 +203,8 @@ func getHTMLRenderer(defaultFlags int, ctx *RenderingContext) blackfriday.Render
|
|||
}
|
||||
|
||||
return &HugoHTMLRenderer{
|
||||
FileResolver: ctx.FileResolver,
|
||||
LinkResolver: ctx.LinkResolver,
|
||||
Renderer: blackfriday.HtmlRendererWithParameters(htmlFlags, "", "", renderParameters),
|
||||
RenderingContext: ctx,
|
||||
Renderer: blackfriday.HtmlRendererWithParameters(htmlFlags, "", "", renderParameters),
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -29,8 +29,7 @@ type FileResolverFunc func(ref string) (string, error)
|
|||
// HugoHTMLRenderer wraps a blackfriday.Renderer, typically a blackfriday.Html
|
||||
// Enabling Hugo to customise the rendering experience
|
||||
type HugoHTMLRenderer struct {
|
||||
FileResolver FileResolverFunc
|
||||
LinkResolver LinkResolverFunc
|
||||
*RenderingContext
|
||||
blackfriday.Renderer
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue