diff --git a/src/client/routes/index.tsx b/src/client/routes/index.tsx index fbcb864..cee3b9e 100644 --- a/src/client/routes/index.tsx +++ b/src/client/routes/index.tsx @@ -1,4 +1,13 @@ -import { Alert, CircularProgress } from "@mui/material"; +import { + Alert, + CircularProgress, + Table, + TableBody, + TableCell, + TableContainer, + TableHead, + TableRow, +} from "@mui/material"; import { useQuery } from "@tanstack/react-query"; import { createFileRoute } from "@tanstack/react-router"; import { useEffect } from "react"; @@ -45,6 +54,30 @@ function RouteComponent() { ) : announcementsQuery.status === "error" ? ( Error (see console) ) : ( -
{JSON.stringify(announcementsQuery.data, null, 2)}
+ //
{JSON.stringify(announcementsQuery.data, null, 2)}
+ + + + + + Title + Text + Publication Date + + + + {announcementsQuery.data.map((a) => ( + + {a.id} + {a.title} + + {a.text.substring(0, 50) + (a.text.length > 50 ? "..." : "")} + + {a.publication_date.toString()} + + ))} + +
+
); }