I have a wallet connection setup where I eagerly connect to the wallet using provider.connect({ onlyIfTrusted: true })
. When a user clicks disconnect I call provider.disconnect()
.
Now when they refresh the page, I do not want Phantom to eagerly reconnect! they just disconnected so it should not reconnect!
I can fix this by removing eagerly reconnect but having to reconnect the wallet everytime after reloading the page is a bad UX. I can see places like Jupiter etc have this UX so I know its possible.
Thank you,