From 5af5f117dfa2922378f90f33d14ea31b4cba28e8 Mon Sep 17 00:00:00 2001 From: kensiiwasaki Date: Wed, 22 Nov 2023 08:48:01 +0900 Subject: [PATCH] =?UTF-8?q?modify:=20TODO=E8=BF=BD=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/routes/index.tsx | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) diff --git a/app/routes/index.tsx b/app/routes/index.tsx index fa35981..00a1590 100644 --- a/app/routes/index.tsx +++ b/app/routes/index.tsx @@ -10,13 +10,7 @@ import { Button, Title } from "@mantine/core"; import { PrismaClient } from "@prisma/client"; import type { ActionFunction, LoaderFunction } from "@remix-run/node"; import { json } from "@remix-run/node"; -import { - Form, - Link, - useActionData, - useLoaderData, - useNavigation, -} from "@remix-run/react"; +import { Form, Link, useActionData, useNavigation } from "@remix-run/react"; import { OpenAI } from "openai"; import { NormalPrompt } from "~/util/prompt"; @@ -69,7 +63,8 @@ export const action: ActionFunction = async (args) => { }; export default function Index() { - const data = useLoaderData(); + // TODO:データの有無で画面を切り替えようと思った + // const data = useLoaderData(); const { signOut } = useClerk(); const actionData = useActionData(); const navigation = useNavigation(); @@ -78,8 +73,6 @@ export default function Index() { const ingredients = actionData ? actionData.response.ingredients : []; const instructions = actionData ? actionData.response.instructions : ""; - console.log(data); - return ( <>