Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ColorFromString ¶
ColorFromString returns a CSS color string by hashing the incoming string. Used to visually identify different versions.
func FriendlyTime ¶
func JSONString ¶
func RelativeTime ¶
Types ¶
type TemplateGroup ¶
type TemplateGroup struct {
// contains filtered or unexported fields
}
func (*TemplateGroup) GetTemplate ¶
func (g *TemplateGroup) GetTemplate(name string) *template.Template
func (*TemplateGroup) LoadTemplates ¶
func (g *TemplateGroup) LoadTemplates() *template.Template
LoadTemplates loads the templates for our toy server
func (*TemplateGroup) Render ¶
func (g *TemplateGroup) Render(w http.ResponseWriter, name string, context interface{})
func (*TemplateGroup) SetConfig ¶
func (g *TemplateGroup) SetConfig(debug bool)
Click to show internal directories.
Click to hide internal directories.