From a34b1ef276da4a16b5e7ff9860c02831d7e281b7 Mon Sep 17 00:00:00 2001 From: Baitinq Date: Sun, 23 Jun 2024 10:32:33 +0200 Subject: Misc: Move type declaration to special folder --- src/lib/types.tsx | 7 +++++++ src/pages/Home.tsx | 8 -------- 2 files changed, 7 insertions(+), 8 deletions(-) create mode 100644 src/lib/types.tsx diff --git a/src/lib/types.tsx b/src/lib/types.tsx new file mode 100644 index 0000000..8e0fda4 --- /dev/null +++ b/src/lib/types.tsx @@ -0,0 +1,7 @@ +type File = { + id: number + user_id: string + absolute_path: string + contents: string + timestamp: string +} diff --git a/src/pages/Home.tsx b/src/pages/Home.tsx index 6244ac5..8bda03b 100644 --- a/src/pages/Home.tsx +++ b/src/pages/Home.tsx @@ -2,14 +2,6 @@ import { useEffect, useState, useCallback } from "react" import { useNavigate } from "react-router-dom" -interface File { - id: number - user_id: string - absolute_path: string - contents: string - timestamp: string -} - export default function Home(props: any) { const navigate = useNavigate() -- cgit 1.4.1