import { QueryClient } from "@tanstack/react-query";

const defaultOptions = {
  queries: {
    gcTime: 10 * 60 * 1000,
    refetchOnWindowFocus: false,
    retry: 1,
    staleTime: 30 * 1000
  },
  mutations: {
    retry: 0
  }
};

export function createAdminQueryClient() {
  return new QueryClient({ defaultOptions });
}

export const queryClient = createAdminQueryClient();
