import { useQuery } from '@tanstack/react-query';
import { fetchConfig } from '../api';
import { STALE_TIME } from '../lib/constants.js';

export function useConfig() {
  return useQuery({ queryKey: ['config'], queryFn: fetchConfig, staleTime: STALE_TIME.SEMI_STATIC });
}
