all repos — gomponents @ a9890f5337da4fc09c016d031b38e36d7b382f62

HTML components in pure Go

Add "checked" bool attribute (#136) Fixes #127.

Markus Wüstenberg
commit

a9890f5337da4fc09c016d031b38e36d7b382f62

parent

4f9709afcc83b617f17f8e5757d58a55be7bf2cf

2 files changed, 5 insertions(+), 0 deletions(-)

changed files
M html/attributes.gohtml/attributes.go
@@ -16,6 +16,10 @@ func AutoPlay() g.Node {
return g.Attr("autoplay") } +func Checked() g.Node { + return g.Attr("checked") +} + func Controls() g.Node { return g.Attr("controls") }
M html/attributes_test.gohtml/attributes_test.go
@@ -14,6 +14,7 @@ cases := map[string]func() g.Node{
"async": Async, "autofocus": AutoFocus, "autoplay": AutoPlay, + "checked": Checked, "controls": Controls, "defer": Defer, "disabled": Disabled,