diff options
Diffstat (limited to 'examples')
-rw-r--r-- | examples/dot-import/dot-import.go | 2 | ||||
-rw-r--r-- | examples/simple/simple.go | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/examples/dot-import/dot-import.go b/examples/dot-import/dot-import.go index 1d595b8..d735785 100644 --- a/examples/dot-import/dot-import.go +++ b/examples/dot-import/dot-import.go @@ -40,5 +40,5 @@ func Navbar(currentPath string) g.Node { } func NavbarLink(href, name, currentPath string) g.Node { - return A(href, Classes{"is-active": currentPath == href}, g.Text(name)) + return A(Href(href), Classes{"is-active": currentPath == href}, g.Text(name)) } diff --git a/examples/simple/simple.go b/examples/simple/simple.go index 529cf18..c872512 100644 --- a/examples/simple/simple.go +++ b/examples/simple/simple.go @@ -64,7 +64,7 @@ func navbar(props navbarProps) g.Node { lis := g.Map(len(items), func(i int) g.Node { item := items[i] return h.Li( - h.A(item.path, c.Classes(map[string]bool{"is-active": props.path == item.path}), g.Text(item.text)), + h.A(h.Href(item.path), c.Classes(map[string]bool{"is-active": props.path == item.path}), g.Text(item.text)), ) }) return h.Ul(h.Class("nav"), g.Group(lis)) |