Skip to content

Commit 622aa6e

Browse files
committed
chore: add utils/date
1 parent 0c834fb commit 622aa6e

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/utils/date.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
export const formatDate = (date: string | Date) => (date instanceof Date ? date : new Date(date)).toLocaleString('en-US', { day: 'numeric', month: 'long', year: 'numeric' })

0 commit comments

Comments
 (0)