You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The way I handle session updates is different from how SessionProvider does it. I have my own SessionProvider that would call a debounced getSession that fires when there's keydowns, mouse moves, or scrolls, etc., which would update the session state if there were any updates to the fetched data.
Now I have no choice but to use what is provided by this library since it creates an internal getSession only through SessionProvider, and it's needed in order to use signOut.
I would be fine with this but using the library version is causing me issues that I didn't have when I handled it myself.
This discussion was converted from issue #3806 on February 12, 2022 23:43.
Heading
Bold
Italic
Quote
Code
Link
Numbered list
Unordered list
Task list
Attach files
Mention
Reference
Menu
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Description 📓
The way I handle session updates is different from how SessionProvider does it. I have my own SessionProvider that would call a debounced getSession that fires when there's keydowns, mouse moves, or scrolls, etc., which would update the session state if there were any updates to the fetched data.
Now I have no choice but to use what is provided by this library since it creates an internal getSession only through SessionProvider, and it's needed in order to use signOut.
I would be fine with this but using the library version is causing me issues that I didn't have when I handled it myself.
What I think would help is if
https://github.com/nextauthjs/next-auth/blob/v4.2.1/src/react/index.tsx#L320-L359
was exposed through https://github.com/nextauthjs/next-auth/blob/v4.2.1/src/react/index.tsx#L410-L415
as something like
since it does all the event broadcasting.
How to reproduce ☕️
no example.
Contributing 🙌🏽
Yes, I am willing to help implement this feature in a PR
Beta Was this translation helpful? Give feedback.
All reactions