Tengo esto en react con typescript: import BodyPage from "@/components/page/BodyPage";
import HeaderBreadCrumbs from "@/components/page/HeaderBreadCrumbs";
import { Button } from "@/components/ui/button";
import { DataTableDemo } from "./ProfileTable";
import { fetchGetProfiles } from "@/rquery/services/profile";

const ProfilesPage = () => {
  const breadCrumbs = [
    { name: "Administración", url: "/administracion/perfiles" },
    { name: "Perfiles", url: "/administracion/perfiles" },
  ];

  const { data } = fetchGetProfiles();
  console.log(data);
  return (
    <div className="w-full justify-center">
      <HeaderBreadCrumbs
        title="Administración de perfiles"
        links={breadCrumbs}
      />
      <BodyPage>
        {/* Filtros */}
        <div className="w-full flex justify-end">
          <Button>Nuevo perfil</Button>
        </div>
        {/* Tabla de perfiles */}
        <DataTableDemo />
      </BodyPage>
    </div>
  );
};

export default ProfilesPage; y este error: Property 'data' does not exist on type 'Promise<ProfileDTO>'.ts(2339)
const data: any asi es fetchGetProfiles: import { ProfileDTO } from "@/interfaces/dto/profile.dto";
import { CreateProfileForm } from "@/interfaces/forms/create-profile.interface";
import FetchWithAuth from "@/utils/FetchWithAuth";

const API_URL: string = import.meta.env.VITE_API_URL as string;

export const fetchCreateProfile = async (
  data: CreateProfileForm
): Promise<ProfileDTO> => {
  try {
    const res = await FetchWithAuth(`${API_URL}profile/create`, "POST", data);

    if ("json" in res) {
      const result = (await res.json()) as ProfileDTO;

      if (result.FlgOk === 1) {
        return result;
      }
    }

    return { FlgOk: 0, message: "Error en crear perfil", data: null };
  } catch (err) {
    console.log("Error in create profile", err);
    return { FlgOk: 0, message: "Error en crear perfil", data: null };
  }
};
export const fetchGetProfiles = async (): Promise<ProfileDTO> => {
  try {
    const res = await FetchWithAuth(`${API_URL}profile`);

    if ("json" in res) {
      const result = (await res.json()) as ProfileDTO;
      console.log("result", result);

      if (result.FlgOk === 1) {
        return result;
      }
    }

    return { FlgOk: 0, message: "Error en obtener perfiles", data: null };
  } catch (err) {
    console.log("Error in create profile", err);
    return { FlgOk: 0, message: "Error en obtener perfiles", data: null };
  }
};
import { ProfileDTO } from "@/interfaces/dto/profile.dto";
import { CreateProfileForm } from "@/interfaces/forms/create-profile.interface";
import FetchWithAuth from "@/utils/FetchWithAuth";

const API_URL: string = import.meta.env.VITE_API_URL as string;

export const fetchCreateProfile = async (
  data: CreateProfileForm
): Promise<ProfileDTO> => {
  try {
    const res = await FetchWithAuth(`${API_URL}profile/create`, "POST", data);

    if ("json" in res) {
      const result = (await res.json()) as ProfileDTO;

      if (result.FlgOk === 1) {
        return result;
      }
    }

    return { FlgOk: 0, message: "Error en crear perfil", data: null };
  } catch (err) {
    console.log("Error in create profile", err);
    return { FlgOk: 0, message: "Error en crear perfil", data: null };
  }
};
export const fetchGetProfiles = async (): Promise<ProfileDTO> => {
  try {
    const res = await FetchWithAuth(`${API_URL}profile`);

    if ("json" in res) {
      const result = (await res.json()) as ProfileDTO;
      console.log("result", result);

      if (result.FlgOk === 1) {
        return result;
      }
    }

    return { FlgOk: 0, message: "Error en obtener perfiles", data: null };
  } catch (err) {
    console.log("Error in create profile", err);
    return { FlgOk: 0, message: "Error en obtener perfiles", data: null };
  }
};
 import { Profile } from "../models/profile.interface";
import { ResponseBackDTO } from "./response.dto";

export interface ProfileDTO extends ResponseBackDTO {
  data?: { profile: Profile } | null;
}
import { Menu } from "./menu.interface";

export interface Profile {
  id: number;
  profile: string;
  description?: string;
  createdAt?: Date;
  updatedAt?: Date;
  deletedAt?: Date;
  menu?: Menu[];
}