diff options
| author | eltrac <hi@eltr.ac> | 2026-10-31 17:16:09 +0800 |
|---|---|---|
| committer | eltrac <hi@eltr.ac> | 2026-10-31 17:16:09 +0800 |
| commit | 2df365606cdff9b12b56c85cc0020602a4ee1bb0 (patch) | |
| tree | 0f63a19a456acc7e5d68c2b5e1ef3935b50c36b8 /builder/base.scm | |
| parent | 31bccb5c8bb74eedf36177833082a1bf62c2ea61 (diff) | |
add lastmod
Diffstat (limited to 'builder/base.scm')
| -rw-r--r-- | builder/base.scm | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/builder/base.scm b/builder/base.scm index 17b7967..31cbf2d 100644 --- a/builder/base.scm +++ b/builder/base.scm @@ -2,6 +2,7 @@ #:use-module (haunt site) #:use-module (builder components) #:use-module (builder includes) + #:use-module (srfi srfi-19) #:use-module (json) #:export (base-template contained-template @@ -69,7 +70,11 @@ (assq-ref metadata 'title) `(div (@ (class "container wider")) (main (@ (class "page prose")) ` - ,,body) + ,,body + ,(let ((lastmod (assq-ref metadata 'lastmod))) + (when lastmod + `(p (@ (class "prose-container small")) + "Last modified: " ,(date->string lastmod "~Y-~m-~d ~H:~M"))))) (footer (@ (style "margin: 2rem 0")) ,(navigation))))) |
