From 7c1d170909f987bc448a7790208fb2a495857a37 Mon Sep 17 00:00:00 2001 From: Sindre Kjelsrud Date: Sat, 6 Jan 2024 21:35:20 +0100 Subject: [PATCH] :speech_balloon: update year in logs to be dynamic Signed-off-by: Sindre Kjelsrud --- src/pages/logs/books.astro | 4 +++- src/pages/logs/watched.astro | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/pages/logs/books.astro b/src/pages/logs/books.astro index 10c690c..2437aa4 100644 --- a/src/pages/logs/books.astro +++ b/src/pages/logs/books.astro @@ -20,11 +20,13 @@ function getEmojiStars(rating:any) { } return stars; } + +const today = new Date(); ---

📚 ¿Dónde está la biblioteca?

-

2023 - Currently Reading:

+

{today.getFullYear()} - Currently Reading:

📖 Multiverses: An Anthology of Alternate Realities

{sortedYears.map(year => (
diff --git a/src/pages/logs/watched.astro b/src/pages/logs/watched.astro index 964a4a8..4850063 100644 --- a/src/pages/logs/watched.astro +++ b/src/pages/logs/watched.astro @@ -20,11 +20,13 @@ function getEmojiStars(rating:any) { } return stars; } + +const today = new Date(); ---

📺 La télévision

-

2023 - Currently Watching:

+

{today.getFullYear()} - Currently Watching:

👀 ONE PIECE Egghead Arc

👀 Star Wars: The Clone Wars S02

{sortedYears.map(year => (