move CompileMarkdown to package

This commit is contained in:
Egor Kovetskiy
2019-04-14 13:53:44 +03:00
parent ada6f828ff
commit 5f582e51e6
4 changed files with 83 additions and 84 deletions

View File

@@ -1,19 +1 @@
package main
import (
"bytes"
"github.com/russross/blackfriday"
)
type ConfluenceRenderer struct {
blackfriday.Renderer
}
func (renderer ConfluenceRenderer) BlockCode(
out *bytes.Buffer,
text []byte,
lang string,
) {
out.WriteString(MacroCode{lang, text}.Render())
}