1 parent 803b730 commit 91eae8bCopy full SHA for 91eae8b
1 file changed
apps/web/app/components/TimeAgo.tsx
@@ -14,8 +14,8 @@ export function TimeAgo({ date }: { date: string | Date | null | undefined }) {
14
return () => clearInterval(timer);
15
}, []);
16
17
- if (!date) return <span>-</span>;
+ if (!date) return <span suppressHydrationWarning>-</span>;
18
const value = dayjs(date);
19
- if (!value.isValid()) return <span>-</span>;
20
- return <span>{value.fromNow()}</span>;
+ if (!value.isValid()) return <span suppressHydrationWarning>-</span>;
+ return <span suppressHydrationWarning>{value.fromNow()}</span>;
21
}
0 commit comments