| 1 | package render |
| 2 | |
| 3 | import ( |
| 4 | "fmt" |
| 5 | "html/template" |
| 6 | ) |
| 7 | |
| 8 | // Included helper functions for use when rendering HTML. |
| 9 | var helperFuncs = template.FuncMap{ |
| 10 | "yield": func() (string, error) { |
| 11 | return "", fmt.Errorf("yield called with no layout defined") |
| 12 | }, |
| 13 | "partial": func() (string, error) { |
| 14 | return "", fmt.Errorf("block called with no layout defined") |
| 15 | }, |
| 16 | "current": func() (string, error) { |
| 17 | return "", nil |
| 18 | }, |
| 19 | } |