mirror of
https://github.com/CopilotKit/CopilotKit.git
synced 2026-09-14 16:26:20 +08:00
0dfb539d2d
* swap docs * fix build error --------- Co-authored-by: Fuma Nama <fuma-nama@noreply.com>
12 lines
428 B
Plaintext
12 lines
428 B
Plaintext
### Specify `"use client"` (Next.js App Router)
|
|
|
|
<Callout type="info">
|
|
This is only necessary if you are using Next.js with the App Router.
|
|
</Callout>
|
|
|
|
```tsx title="YourComponent.tsx"
|
|
"use client"
|
|
```
|
|
|
|
Like other React hooks such as `useState` and `useEffect`, this is a **client-side** hook.
|
|
If you're using Next.js with the App Router, you'll need to add the `"use client"` directive at the top of any file using this hook. |