about summary refs log tree commit diff stats
path: root/html/elements.go
diff options
context:
space:
mode:
Diffstat (limited to 'html/elements.go')
-rw-r--r--html/elements.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/html/elements.go b/html/elements.go
index 8045561..4f1a0ec 100644
--- a/html/elements.go
+++ b/html/elements.go
@@ -14,13 +14,13 @@ func A(href string, children ...g.Node) g.NodeFunc {
 	return g.El("a", g.Attr("href", href), g.Group(children))
 }
 
-// Document returns an special kind of Node that prefixes its child with the string "<!doctype html>".
-func Document(child g.Node) g.NodeFunc {
+// Doctype returns a special kind of Node that prefixes its sibling with the string "<!doctype html>".
+func Doctype(sibling g.Node) g.NodeFunc {
 	return func(w io.Writer) error {
 		if _, err := w.Write([]byte("<!doctype html>")); err != nil {
 			return err
 		}
-		return child.Render(w)
+		return sibling.Render(w)
 	}
 }