init - add project files
This commit is contained in:
11
ui/markdown.go
Normal file
11
ui/markdown.go
Normal file
@@ -0,0 +1,11 @@
|
||||
package ui
|
||||
|
||||
import (
|
||||
"github.com/gomarkdown/markdown"
|
||||
. "maragu.dev/gomponents"
|
||||
)
|
||||
|
||||
func Markdown(input string) Node {
|
||||
html := markdown.ToHTML([]byte(input), nil, nil)
|
||||
return SafeRaw(string(html))
|
||||
}
|
||||
Reference in New Issue
Block a user