Netscape Navigator 3.0
Location:

Blog supports markdown

Published Thu, 01 Jan 2026 09:30:00 UTC

Blog posts are now being parsed out of files and the content supports markdown. I'm using the goldmark package to render the content as a templ.Component:

 1type Post struct {
 2	Title     string
 3	Date      time.Time
 4	Content   string
 5}
 6
 7func (p Post) Render() templ.Component {
 8	return templ.ComponentFunc(func(ctx context.Context, w io.Writer) (err error) {
 9        return goldmark.Convert([]byte(p.Content), w)
10	})
11}