Next.js · Junior · Question 70 of 75
Do you need 'use client' at the top of every client component file?
- ✓Correct answer: No - only at the boundary; modules imported from a client file become part of the client bundle
- 2Yes, every file with JSX needs it
- 3Yes, otherwise the component renders twice
Explanation
'use client' marks the entry point from server to client. Adding it everywhere isn't harmful but makes it harder to see where the boundary is.