Skip to content

Commit 9aa8830

Browse files
committed
fix: replace blog ISO dates with readable dates
1 parent dc3ae56 commit 9aa8830

3 files changed

Lines changed: 6 additions & 7 deletions

File tree

src/routes/_libraries/blog.$.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ function BlogPost() {
101101

102102
const blogContent = `<small>_by ${formatAuthors(authors)} on ${format(
103103
new Date(published || 0),
104-
'MMM dd, yyyy',
104+
'MMM d, yyyy',
105105
)}._</small>
106106
107107
${content}`

src/routes/_libraries/blog.index.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -88,10 +88,10 @@ function BlogIndex() {
8888
{published ? (
8989
<time
9090
dateTime={published}
91-
title={format(new Date(published), 'MMM dd, yyyy')}
91+
title={format(new Date(published), 'MMM d, yyyy')}
9292
>
9393
{' '}
94-
on {format(new Date(published), 'MMM dd, yyyy')}
94+
on {format(new Date(published), 'MMM d, yyyy')}
9595
</time>
9696
) : null}
9797
</p>

src/routes/_libraries/index.tsx

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
import { Link, MatchRoute, createFileRoute } from '@tanstack/react-router'
2-
import { twMerge } from 'tailwind-merge'
1+
import { Link, createFileRoute } from '@tanstack/react-router'
32
import { Footer } from '~/components/Footer'
43
import { LazySponsorSection } from '~/components/LazySponsorSection'
54
import discordImage from '~/images/discord-logo-white.svg'
@@ -385,11 +384,11 @@ function Index() {
385384
dateTime={published}
386385
title={format(
387386
new Date(published),
388-
'MMM dd, yyyy',
387+
'MMM d, yyyy',
389388
)}
390389
>
391390
{' '}
392-
on {format(new Date(published), 'MMM dd, yyyy')}
391+
on {format(new Date(published), 'MMM d, yyyy')}
393392
</time>
394393
) : null}
395394
</p>

0 commit comments

Comments
 (0)