Add links to godoc (#183) Also add an example for `http.Adapt`. Fixes #182
1 file changed, 3 insertions(+), 2 deletions(-)
changed files
M components/components.go → components/components.go
@@ -10,7 +10,7 @@ g "github.com/maragudk/gomponents" . "github.com/maragudk/gomponents/html" ) -// HTML5Props for HTML5. +// HTML5Props for [HTML5]. // Title is set no matter what, Description and Language elements only if the strings are non-empty. type HTML5Props struct { Title string@@ -41,6 +41,7 @@ // The attribute value is a sorted, space-separated string of all the map keys, // for which the corresponding map value is true. type Classes map[string]bool +// Render satisfies [g.Node]. func (c Classes) Render(w io.Writer) error { var included []string for c, include := range c {@@ -56,7 +57,7 @@ func (c Classes) Type() g.NodeType { return g.AttributeType } -// String satisfies fmt.Stringer. +// String satisfies [fmt.Stringer]. func (c Classes) String() string { var b strings.Builder _ = c.Render(&b)