update markdown

This commit is contained in:
aichy126 2023-04-26 17:30:32 +08:00
parent f28b743519
commit 78850be999
1 changed files with 1 additions and 1 deletions

View File

@ -46,7 +46,7 @@ func Markdown2HTML(source string) string {
func Markdown2BasicHTML(source string) string {
content := Markdown2HTML(source)
filter := bluemonday.NewPolicy()
filter.AllowElements("p", "b", "br")
filter.AllowElements("p", "b", "br", "strong", "em")
filter.AllowAttrs("src").OnElements("img")
filter.AddSpaceWhenStrippingTag(true)
content = filter.Sanitize(content)