/* Template that grew in complexity recently. It's was first template that supports JS. 1. Template contains local templ blocks their names starting with lowercase to make it DRY 2. JS script is seperated and should be called *after* page construction. 3. Templ ShowBlogPage contains some math to dynamicly reduce post size TODO - make it more DRY and modular in general */ package templates import "github.com/dixxe/personal-website/web/static/styling" import "github.com/dixxe/personal-website/iternal/pkg/repositories" import "fmt" import "strings" import "math" var markedHandle = templ.NewOnceHandle() templ runMarked(markdown string) { @templ.JSONScript("md", markdown) @markedHandle.Once() { } } templ blogHeader() {
Вернуться Домой
{strings.Join(shortStr, " ")}...
Читать полностью...