Consolidate authentication code

This commit is contained in:
april
2024-01-03 10:01:15 -06:00
parent 73b11482ff
commit 912e4d1b0e
12 changed files with 206 additions and 114 deletions

View File

@@ -1,12 +1,11 @@
import { client } from "@/util/api";
import { List, Stack, Text } from "@mantine/core";
import { useParams } from "@remix-run/react";
import { useQuery, useQueryClient } from "@tanstack/react-query";
import { useQuery } from "@tanstack/react-query";
export default function Flight() {
const params = useParams();
const queryClient = useQueryClient();
const flight = useQuery({
queryKey: [params.id],
queryFn: async () =>