burning.moe/internal/models/templatecache.go
Lilian Jónsdóttir a7f6bb35e7 it works!
initial build that basically replicates my old HTML site
2024-01-22 20:10:14 -08:00

19 lines
378 B
Go

package models
import (
"html/template"
"time"
)
// TemplateCache holds the template cache as map of TemplateCacheItem
type TemplateCache struct {
Cache map[string]TemplateCacheItem
}
// TemplateCacheItem holds a pointer to a generated
// template, and the time it was generated at.
type TemplateCacheItem struct {
Template *template.Template
GeneratedAt time.Time
}