Documentation ¶
Index ¶
- func Add(a, b int) int
- func AddDefaultData(td *models.TemplateData, r *http.Request) *models.TemplateData
- func CreateTemplateCache() (map[string]*template.Template, error)
- func FormatDate(d time.Time) string
- func FormatDateWithLayout(t time.Time, l string) string
- func Iterate(count int) []int
- func NewRenderer(appConfig *config.AppConfig)
- func Template(w http.ResponseWriter, r *http.Request, tmpl string, td *models.TemplateData) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddDefaultData ¶
func AddDefaultData(td *models.TemplateData, r *http.Request) *models.TemplateData
func CreateTemplateCache ¶
CreateTemplateCache creates a template cache as a map
func FormatDate ¶
func NewRenderer ¶
NewRenderer sets the config for the template package
func Template ¶
func Template(w http.ResponseWriter, r *http.Request, tmpl string, td *models.TemplateData) error
Template renders a template
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.