import { useQuery } from "@tanstack/react-query";
import { getReviews } from "../api/reviews.api";

export const useReviews = () =>
  useQuery({
    queryKey: ["reviews"],
    queryFn: getReviews,
    staleTime: 1000 * 60 * 10,
    refetchOnWindowFocus: false,
  });
