allow empty scheme
Add text filter option
extend API
Library for converting Gemtext to HTML
Based on adamcleod/gmi2html.
This is used for fishbb in the conext of post bodies and has some configuration options that you may find useful.
package main
import (
"fmt"
"os"
"git.sr.ht/~aw/gmi2html"
)
func main() {
// simple conversion with default values
html := gmi2html.ConvertString("#hello\n=> https://google.com world")
fmt.Println(html)
// initialization and configuration
r := gmi2html.NewReader(os.stdin)
r.NestedBlocks = true
r.WriteHTML(os.stdout)
}