Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Helpers = map[string]interface{}{ "js_escape": template.JSEscapeString, "html_escape": template.HTMLEscapeString, "json": ToJSON, "content_for": ContentFor, "content_of": ContentOf, "upcase": strings.ToUpper, "downcase": strings.ToLower, "markdown": Markdown, "debug": Debug, }
Helpers that are automatically injected into templates.
Functions ¶
func ContentFor ¶
ContentFor stores a block of templating code to be re-used later in the template.
{{content_for "buttons"}} <button>hi</button> {{/content_for}}
func ContentOf ¶
func ContentOf(name string, options *raymond.Options) raymond.SafeString
ContentOf retrieves a stored block for templating and renders it.
{{content_of "buttons"}}
func Debug ¶ added in v0.5.1
func Debug(v interface{}) raymond.SafeString
Debug by verbosely printing out using 'pre' tags.
func Markdown ¶ added in v0.5.1
func Markdown(body string) raymond.SafeString
Markdown converts the string into HTML using GitHub flavored markdown.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.