mirror of
https://github.com/mindoc-org/mindoc.git
synced 2025-04-05 20:17:53 +08:00
优化Markdown解析
This commit is contained in:
parent
970e77f71c
commit
ffe5dced44
@ -620,7 +620,11 @@ func (book *Book) ImportBook(zipPath string) error {
|
|||||||
return link
|
return link
|
||||||
})
|
})
|
||||||
|
|
||||||
doc.Content = string(blackfriday.Run([]byte(doc.Markdown)))
|
doc.Content = string(blackfriday.Run([]byte(doc.Markdown),
|
||||||
|
blackfriday.WithExtensions(blackfriday.Tables),
|
||||||
|
blackfriday.WithExtensions(blackfriday.HeadingIDs),
|
||||||
|
blackfriday.WithExtensions(blackfriday.FencedCode),
|
||||||
|
blackfriday.WithExtensions(blackfriday.AutoHeadingIDs)))
|
||||||
|
|
||||||
doc.Version = time.Now().Unix()
|
doc.Version = time.Now().Unix()
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user