Pinia Disasterclass
summary
Four-year-old Pinia gets a lessons-learned audit: concrete anti-patterns (stop mapping Vuex mutations/getters to Pinia, don't cast empty object), TypeScript fixes (use generics on refs instead of sham casts), lifecycle rules (stores are lazy; never export a pre-created store instance), runtime choices (prefer ref for arrays, avoid readonly/state-externalization that breaks SSR and DevTools), and architecture advice: use the router/URL as source of truth and treat stores as composable singletons with caching and route-driven watchers.
AI-written summary · about
chapters (18)
- 0:00Introduction
- 2:30Common mistakes
- 4:06Mutating state
- 6:01Self sabotage
- 8:07Readonly state
- 10:19Casting empty objects
- 11:39Fixing the error
- 12:44New patterns
- 18:09Reactive ref
- 19:48Overusing stores
- 23:04Composable stores
- 25:52Questions
- 26:14Benefits
- 29:09Syntax
- 30:54Challenges and rewards
- 33:34Misconceptions
- 35:44Factory Patterns
- 37:59Dep tool support
related talks
28mPinia Disasterclass
25mEverything Beyond State Management in Stores with Pinia
30mProven Pinia Patterns
32mProven Pinia Patterns
48mVUE3 & Pinia A Better Pattern for Global State Management
28mGetting more out of your Pinia Stores
33mPanel Discussion – State Management
16mEffortless State Management in Nuxt 3 with Pinia: Practical Guide
