Replies: 3 comments 2 replies
-
hey @backseats, im not entirely sure what the issue is here. the only thing i see in your example that could be the issue is this: useEffect(() => {
async function sign_out() {
await signOut?.();
}
if (address || isConnected) {
// TODO: POST the address to the backend
- signOut?.()
+ sign_out()
}
}, [address, isConnected]); other than that, this should work as expected. what are the results you're seeing exactly? |
Beta Was this translation helpful? Give feedback.
0 replies
-
I’d expect the user’s wallet to no longer be connected and to not get an address through the useAccount hook after calling signOut
…On Jun 20, 2024 at 7:49 AM -0400, Lochie Axon ***@***.***>, wrote:
hey @backseats, im not entirely sure what the issue is here. the only thing i see in your example that could be the issue is this:
useEffect(() => {
async function sign_out() {
await signOut?.();
}
if (address || isConnected) {
// TODO: POST the address to the backend
- signOut?.()
+ sign_out?.()
}
}, [address, isConnected]);
other than that, this should work as expected. what are the results you're seeing exactly?
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you were mentioned.Message ID: ***@***.***>
|
Beta Was this translation helpful? Give feedback.
1 reply
-
Ah! I missed that hook. Thanks Lochie!
…On Jun 20, 2024 at 8:22 AM -0400, Lochie Axon ***@***.***>, wrote:
signOut signs out the approved session, you'll want to disconnect the wallet on top of this as these are two different things.
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you were mentioned.Message ID: ***@***.***>
|
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
lochie
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'm building a flow where the user signs in, we log their address in the backend, and it signs them out automatically, so they don't have to remain signed in. I'm trying to use the
useSIWE
hook butsiweContextValue
isn't truthy. Seems like I need to wrap myWeb3Provider
in something and would love some guidance on how to do that.Thanks!
useSIWE.ts
My code
My
layout.tsx
My
page.tsx
Beta Was this translation helpful? Give feedback.
All reactions