mirror of
https://github.com/gabehf/Koito.git
synced 2026-04-22 20:11:50 -07:00
wip
This commit is contained in:
parent
6b73f83484
commit
b5e8d88451
29 changed files with 1271 additions and 963 deletions
16
client/app/routes/RewindPage.tsx
Normal file
16
client/app/routes/RewindPage.tsx
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
import Rewind from "~/components/rewind/Rewind";
|
||||
import type { Route } from "./+types/Home";
|
||||
import { getRewindStats, type RewindStats } from "api/api";
|
||||
import { useEffect, useState } from "react";
|
||||
|
||||
export function meta({}: Route.MetaArgs) {
|
||||
return [{ title: "Koito" }, { name: "description", content: "Koito" }];
|
||||
}
|
||||
|
||||
export default function RewindPage() {
|
||||
const [stats, setStats] = useState<RewindStats | undefined>(undefined);
|
||||
useEffect(() => {
|
||||
getRewindStats({ year: 2025 }).then((r) => setStats(r));
|
||||
}, []);
|
||||
return <>{stats !== undefined && <Rewind stats={stats} includeTime />}</>;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue