Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InitTemplates ¶
func InitTemplates(path string)
InitTemplates parses the templates and panics if it can't
func RenderTemplate ¶
func RenderTemplate(w http.ResponseWriter, template string, data interface{})
RenderTemplate writes a template to a Response Panics if the templates haven't been initialized.
Types ¶
type PageInfo ¶
type PageInfo struct { // Username is populated if the user is logged in Username *string // Error is populated if an error message should be shown Error []string }
PageInfo holds pieces of information that slot into standard placeholders on pages Any field may be null if not applicable
Click to show internal directories.
Click to hide internal directories.