How do we update custom session data without a full page reload?

In my Better Auth Next.js apps, I rely heavily on the custom session plugin to load user-specific data, keeping server and client in sync. However, I'm struggling with how to update this session data without a full page reload, as I want to avoid resetting client state unnecessarily. authClient.useSession() doesn’t seem to support live updates to custom session data. Right now, I copy that data into a custom context and manage updates there, but that forces me to use my own context for auth across the app instead of authClient.useSession(). Is there a better pattern for this?
0 Replies
No replies yetBe the first to reply to this messageJoin

Did you find this page helpful?