tpl/urls: Add anchorize template func

This commit is contained in:
Bjørn Erik Pedersen
2018-04-15 23:17:50 +02:00
parent 880ca19f20
commit 4dba6ce15a
2 changed files with 19 additions and 0 deletions

View File

@@ -59,6 +59,13 @@ func init() {
[][2]string{},
)
ns.AddMethodMapping(ctx.Anchorize,
[]string{"anchorize"},
[][2]string{
{`{{ "This is a title" | anchorize }}`, `this-is-a-title`},
},
)
return ns
}