import { Tweet , User } from "@prisma/client" ; import useSWR from "swr" ; import { fetcher } from "./fetcher" ; export function useFeed ( ) { const { data : feed } = useSWR ( "/api/feed" , fetcher ) ; return { feed } ; } export function useMe ( ) { const { data : me } = useSWR ( "/api/me" , fetcher ) ; return { me } ; }