mirror of
https://github.com/go-gitea/gitea
synced 2025-07-13 14:07:20 +00:00
Handle yaml frontmatter (#11016)
Add goldmark-meta to render yaml frontmatter as a table Fix #5377 Signed-off-by: Andrew Thornton <art27@cantab.net>
This commit is contained in:
@ -16,6 +16,7 @@ import (
|
||||
giteautil "code.gitea.io/gitea/modules/util"
|
||||
|
||||
"github.com/yuin/goldmark"
|
||||
meta "github.com/yuin/goldmark-meta"
|
||||
"github.com/yuin/goldmark/extension"
|
||||
"github.com/yuin/goldmark/parser"
|
||||
"github.com/yuin/goldmark/renderer"
|
||||
@ -53,6 +54,7 @@ func RenderRaw(body []byte, urlPrefix string, wikiMarkdown bool) []byte {
|
||||
extension.Ellipsis: nil,
|
||||
}),
|
||||
),
|
||||
meta.New(meta.WithTable()),
|
||||
),
|
||||
goldmark.WithParserOptions(
|
||||
parser.WithAttribute(),
|
||||
|
Reference in New Issue
Block a user