The CandidAdapter
instance.
function CandidAdapterComponent() {
const candidAdapter = useCandidAdapter();
const getActor = async () => {
const { idlFactory } = await candidAdapter.getCandidDefinition(canisterId)
console.log(idlFactory)
}
return (
<button onClick={getActor}>Get Actor</button>
);
}
Accesses the
CandidAdapter
to download the actor's Candid interface.