From b27c96688785372787eb5c3c71a32767fab71ac4 Mon Sep 17 00:00:00 2001 From: Alan Pearce Date: Tue, 18 Jun 2024 20:13:26 +0200 Subject: split content and sitemap code from builder --- internal/builder/list.templ | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'internal/builder/list.templ') diff --git a/internal/builder/list.templ b/internal/builder/list.templ index 48563ed..24cafe8 100644 --- a/internal/builder/list.templ +++ b/internal/builder/list.templ @@ -1,8 +1,11 @@ package builder -import "website/internal/config" +import ( + "website/internal/config" + "website/internal/content" +) -templ tagPage(config config.Config, tag string, posts []Post, path string) { +templ tagPage(config config.Config, tag string, posts []content.Post, path string) { @page(config, PageSettings{ Title: tag, Path: path, @@ -21,7 +24,7 @@ templ tagPage(config config.Config, tag string, posts []Post, path string) { } } -templ listPage(config config.Config, posts []Post, path string) { +templ listPage(config config.Config, posts []content.Post, path string) { @page(config, PageSettings{ Title: config.Title, TitleAttrs: templ.Attributes{ @@ -34,7 +37,7 @@ templ listPage(config config.Config, posts []Post, path string) { } } -templ list(posts []Post) { +templ list(posts []content.Post) {