diff options
| author | Kyren223 <Kyren223@proton.me> | 2024-11-15 16:56:41 +0200 |
|---|---|---|
| committer | Kyren223 <Kyren223@proton.me> | 2024-11-15 16:56:41 +0200 |
| commit | d1f73304f61ba8062721a7fcb0621e80280e85d2 (patch) | |
| tree | ace1ff3896cd750fcd2b3e9c8e7a130587513433 /src/components/BlogItem.astro | |
| parent | fc001b14c00f530d106400149b9be69837d6952f (diff) | |
Some minor tweaks and updated ssh stuff to the actual values instead of placeholders
Diffstat (limited to 'src/components/BlogItem.astro')
| -rw-r--r-- | src/components/BlogItem.astro | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/src/components/BlogItem.astro b/src/components/BlogItem.astro index 08b98c4..7af463e 100644 --- a/src/components/BlogItem.astro +++ b/src/components/BlogItem.astro @@ -5,17 +5,7 @@ function formatDate(date: Date) { const day = date.getDate(); const month = date.toLocaleString("default", { month: "long" }); const year = date.getFullYear(); - - let suffix = "th"; - if (day === 1 || day === 21 || day === 31) { - suffix = "st"; - } else if (day === 2 || day === 22) { - suffix = "nd"; - } else if (day === 3 || day === 23) { - suffix = "rd"; - } - - return `${month} ${day}${suffix} ${year}`; + return `${month} ${day}, ${year}`; } interface Props { |
