func RenderBlogIndex(w http.ResponseWriter, req *http.Request) { indexTemplate.Execute(w, struct { Entries []models.BlogEntry Title string }{ models.NewEntries(12), "", }) }
func RenderBlogPage(bp models.BlogEntry, w http.ResponseWriter) { entryTemplate.Execute(w, struct { Entry models.BlogEntry NewEntries []models.BlogEntry Categories []models.Category }{ bp, models.NewEntries(3), models.ActiveCategories(), }) }