mirror of
https://github.com/stack-auth/stack.git
synced 2026-06-13 21:01:21 +08:00
[Docs]: Fix typo in server component basics on the getting started guide page (#1085)
Previously, the documentation mentioned importing `stackServerApp` from `stack/client.ts`. This has been updated to reflect where it is actually imported from. Co-authored-by: Konsti Wohlwend <n2d4xc@gmail.com>
This commit is contained in:
parent
d6dc85b6d6
commit
4c6d0131d2
@ -30,7 +30,7 @@ Sometimes, you want to retrieve the user only if they're signed in, and redirect
|
||||
|
||||
## Server Component basics
|
||||
|
||||
Since `useUser()` is a stateful hook, you can't use it on server components. Instead, you can import `stackServerApp` from `stack/client.ts` and call `getUser()`:
|
||||
Since `useUser()` is a stateful hook, you can't use it on server components. Instead, you can import `stackServerApp` from `stack/server.ts` and call `getUser()`:
|
||||
|
||||
```tsx title="my-server-component.tsx"
|
||||
import { stackServerApp } from "@/stack/server";
|
||||
|
||||
Loading…
Reference in New Issue
Block a user