tengo este codigo
type UserService = { getUserRole: () => string } const auth = useAuth(); const useUserService: UserService = { getUserRole: () => { return Axios({ method: "get", url: "https://<url>", headers: { "Authorization": `Bearer ${auth.user.access_token}` } }).then((response) => { return response.data; }).catch((error) => { console.log(error); }); } } export default useUserService estoy recibiendo un mensaje de error
Type '() => Promise<any>' is not assignable to type '() => string'.
Type 'Promise<any>' is not assignable to type 'string' .
¿Cómo devuelvo la response (que es una cadena) de Axios?