Migrate from templates to Gomponents (#103)

This commit is contained in:
Mike Stefanello 2025-03-05 20:01:58 -05:00 committed by GitHub
parent 5cad4cbd33
commit 62d46c475c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
104 changed files with 2768 additions and 2824 deletions

View file

@ -0,0 +1,19 @@
package models
import (
. "maragu.dev/gomponents"
. "maragu.dev/gomponents/html"
)
type SearchResult struct {
Title string
URL string
}
func (s *SearchResult) Render() Node {
return A(
Class("panel-block"),
Href(s.URL),
Text(s.Title),
)
}