import { fetchCharacter } from '@/services/editor';
import { useInfiniteQuery, useMutation, useQuery, useQueryClient } from '@tanstack/react-query';

export function useCharacter(id?: string) {
  return useQuery({
    queryKey: ['character', id],
    queryFn: () => fetchCharacter({ id }),
    enabled: !!id,
  });
}
