onAuthStateChange only registers events when tab is changed (not when a user signs in or signs out) #29427
Unanswered
adityakakarla
asked this question in
Questions
Replies: 2 comments
-
Not sure if this is a better solution, but from what I can see visually it works
|
Beta Was this translation helpful? Give feedback.
0 replies
-
I also have this issue, this is definitely an issue in client components. Not sure how to fix it |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I am using Next.js 14 and Supabase to build a web app. I am trying to build a NavBar that is able to dynamically change based on whether or not the user is signed in (ex: showing Sign Out button vs Log In button).
When a user either logs in or signs out, the event does not initially register. However, it does when you change tabs.
Because this is a Navbar, I would like to have these events registered as soon as the user does the action rather than waiting for them to change tabs. Is there something I'm missing?
One thing that came to mind: this is a Client Component, but my login is implemented as a Sever Action (following Server-Side auth guide).
Beta Was this translation helpful? Give feedback.
All reactions