web3modal icon indicating copy to clipboard operation
web3modal copied to clipboard

[feature] I’d like to perform some extra actions right after the user disconnects in appkit modal.

Open tuzkiiiii233 opened this issue 8 months ago • 4 comments

What problem does this new feature solve?

When using AppKit with a custom modal in a Next.js project, is there a callback or hook I can use to catch the disconnect action directly from the modal, instead of just watching Wagmi’s isDisconnected state? Any help would be super appreciated!

Describe the solution you'd like

When using AppKit with a custom modal in a Next.js project, is there a callback or hook I can use to catch the disconnect action directly from the modal, instead of just watching Wagmi’s isDisconnected state? Any help would be super appreciated!

tuzkiiiii233 avatar Apr 08 '25 02:04 tuzkiiiii233

Image

tuzkiiiii233 avatar Apr 08 '25 02:04 tuzkiiiii233

Hey thanks for the feature request. So I can prioritise this correctly please can you give me some more context on what you would use the disconnect event for?

Sam-Newman avatar Apr 08 '25 10:04 Sam-Newman

Hey thanks for the feature request. So I can prioritise this correctly please can you give me some more context on what you would use the disconnect event for?

For example, after the user clicks “disconnect”, we need to clear the session token, redirect them to a different page, and show a notification or UI prompt.

tuzkiiiii233 avatar Apr 09 '25 01:04 tuzkiiiii233