diff options
author | Bjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com> | 2017-05-01 09:06:42 +0200 |
---|---|---|
committer | Bjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com> | 2017-05-01 15:13:41 +0200 |
commit | 0e2260421e40c97d9d210724fb44cfdc15ea7855 (patch) | |
tree | 13a73d06a67b42584fcd20c08615418e0ec2fe1f /tpl/urls/init.go | |
parent | 4714085a10835b9f4e8d4f699dc94e3120d8067e (diff) |
tpl: Fix the remaining template funcs namespace issues
See #3042
Diffstat (limited to 'tpl/urls/init.go')
-rw-r--r-- | tpl/urls/init.go | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/tpl/urls/init.go b/tpl/urls/init.go index a687704af..fb9b00a27 100644 --- a/tpl/urls/init.go +++ b/tpl/urls/init.go @@ -33,6 +33,7 @@ func init() { {`{{ "http://gohugo.io/" | relURL }}`, `http://gohugo.io/`}, {`{{ "mystyle.css" | relURL }}`, `/hugo/mystyle.css`}, {`{{ mul 2 21 | relURL }}`, `/hugo/42`}, + {`{{ "Bat Man" | urlize }}`, `bat-man`}, } return &internal.TemplateFuncsNamespace{ @@ -45,6 +46,7 @@ func init() { "relURL": ctx.RelURL, "relLangURL": ctx.RelLangURL, "relref": ctx.RelRef, + "urlize": ctx.URLize, }, Examples: examples, } |