aboutsummaryrefslogtreecommitdiffhomepage
path: root/template/functions.go
diff options
context:
space:
mode:
Diffstat (limited to 'template/functions.go')
-rw-r--r--template/functions.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/template/functions.go b/template/functions.go
index 157935d..3b6423f 100644
--- a/template/functions.go
+++ b/template/functions.go
@@ -48,6 +48,9 @@ func (f *funcMap) Map() template.FuncMap {
"route": func(name string, args ...interface{}) string {
return route.Path(f.router, name, args...)
},
+ "safeURL": func(url string) template.URL {
+ return template.URL(url)
+ },
"noescape": func(str string) template.HTML {
return template.HTML(str)
},