import { useQuery } from "@tanstack/react-query";
import { getAttributeTypesOptions } from "@/lib/client/@tanstack/react-query.gen";

const useAttributeTypesList = () => {
    const { data, refetch } = useQuery(getAttributeTypesOptions());

    return {
        attributeTypes: data?.items ?? [],
        refetch,
    };
};

export default useAttributeTypesList;
