mirror of
https://github.com/lukevella/rallly.git
synced 2025-07-28 13:47:43 +02:00
Switch from date-fns to day.js (#213)
This commit is contained in:
parent
368f324865
commit
707eae68c1
19 changed files with 549 additions and 229 deletions
|
@ -1,4 +1,4 @@
|
|||
import { formatRelative } from "date-fns";
|
||||
import dayjs from "dayjs";
|
||||
import Head from "next/head";
|
||||
import Link from "next/link";
|
||||
import { useTranslation } from "next-i18next";
|
||||
|
@ -83,7 +83,7 @@ export const Profile: React.VoidFunctionComponent = () => {
|
|||
</Link>
|
||||
</div>
|
||||
<div className="ml-7 text-sm text-slate-500">
|
||||
{formatRelative(poll.createdAt, new Date())}
|
||||
{dayjs(poll.createdAt).fromNow()}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue