mirror of
https://github.com/LukeHagar/better-auth.git
synced 2025-12-09 12:27:43 +00:00
docs: add note regarding cookie caching and RSC
This commit is contained in:
@@ -91,6 +91,8 @@ export async function ServerComponent() {
|
||||
}
|
||||
```
|
||||
|
||||
<Callout type="warn">As RSCs cannot set cookies, the [cookie cache](/docs/concepts/session-management#cookie-cache) will not be refreshed until the server is interacted with from the client via Server Actions or Route Handlers.</Callout>
|
||||
|
||||
### Server Action Cookies
|
||||
|
||||
When you call a function that needs to set cookies, like `signInEmail` or `signUpEmail` in a server action, cookies won’t be set. This is because server actions need to use the `cookies` helper from Next.js to set cookies.
|
||||
|
||||
Reference in New Issue
Block a user