[X] goldmark is fully compliant with the CommonMark. Before submitting issue, you must read CommonMark spec and confirm your output is different from CommonMark online demo.
[X] Extensions(Autolink without <>, Table, etc) are not part of CommonMark spec. You should confirm your output is different from other official renderers correspond with an extension.
[X] goldmark is not dedicated for Hugo. If you are Hugo user and your issue was raised by your experience in Hugo, you should consider create issue at Hugo repository at first .
Please answer the following before submitting your issue:
What version of goldmark are you using? : 1.5.4
What version of Go are you using? : 1.20.1
What operating system and processor architecture are you using? : Mac
What did you do? : ran the below code
What did you expect to see? : it should print strong
What did you see instead? : it printed emphasis
Did you confirm your output is different from CommonMark online demo or other official renderer correspond with an extension?: yes
var source = `
**This is text**
`
func main() {
doc := goldmark.DefaultParser().Parse(text.NewReader([]byte(source)))
ast.Walk(doc, func(n ast.Node, entering bool) (ast.WalkStatus, error) {
s := ast.WalkStatus(ast.WalkContinue)
var err error
fmt.Println(n.Kind())
return s, err
})
}
Outputs
Document
Paragraph
Emphasis
Text
Text
Emphasis
Paragraph
Document
goldmark has https://github.com/yuin/goldmark/discussions in github. You should post only issues here. Feature requests and questions should be posted at discussions.
<
>
, Table, etc) are not part of CommonMark spec. You should confirm your output is different from other official renderers correspond with an extension.Please answer the following before submitting your issue:
Outputs
It should print like this according to https://spec.commonmark.org/dingus/
It print
emphasis
instead ofstrong