I tried to pass the props like
<Mycomp
deleteAcc={handleDelete(accountId)}
/>
to another component. I write the props like
interface AccProps {
deleteAcc: () => void;
}
and call the function like
deleteAcc()
But I got the below error
Type 'void' is not assignable to type '() => void'
Not sure what I have missed here.