Vue · Senior · Question 26 of 75
How is Pinia state transferred from the server to the client?
- ✓Correct answer: The server serializes
pinia.state.valueinto the page and the client sets it before mounting - 2The client always refetches all stores
- 3Pinia state is stored in cookies
Explanation
Serialization must be safe against XSS (e.g. devalue). Nuxt's Pinia module does this automatically. Non-serializable values (class instances, functions) don't survive.