Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
var TemplateHelpers template.FuncMap
TemplateHelpers - Template helper functions
Functions ¶
func GetField ¶
GetField - Get field and apply the default value(if any)
params -- config {interface{}} The structure -- key {string} The field with the default set -- value {string} The value of that field
returns -- {string} The real value
func GetLink ¶
GetLink - Template helper function to get named router links
params -- routeName {string} Router name to craft the link for -- fields {...string} A flat map of all fields and values to pass to the router
returns -- {string} The url
func GetRouter ¶
GetRouter - Get a router instance (singleton)
params -- newInstance {bool} Optional parameter to force a new instance
returns -- {*mux.Router} Router instance
func GzipString ¶
GzipString - Compress a string with gzip
params -- content {string} The string to compress
returns -- {[]bytes} Compressed data -- {error}
Types ¶
This section is empty.