tplimpl: Add built-in print funcs to FuncMap

Add print, printf, and println to the Hugo FuncMap so that they are
accessible to the apply template func.

Updates #3139
This commit is contained in:
Cameron Moore
2017-03-07 14:11:03 -06:00
committed by Bjørn Erik Pedersen
parent a2a8a651f7
commit 45b9d7223a
2 changed files with 9 additions and 0 deletions

View File

@@ -2152,6 +2152,9 @@ func (t *templateFuncster) initFuncMap() {
"partialCached": t.partialCached,
"plainify": plainify,
"pluralize": pluralize,
"print": fmt.Sprint,
"printf": fmt.Sprintf,
"println": fmt.Sprintln,
"querify": querify,
"readDir": t.readDirFromWorkingDir,
"readFile": t.readFileFromWorkingDir,