Demystifying the Vue Lifecycle
summary
Concrete lifecycle rules and concrete examples: use created for early network calls, use beforeMount dataset pull to seed state from an embedding, use mounted only for DOM-dependent libraries like Chartist, use beforeUpdate/updated for timing vs watches, and use errorCaptured to swallow or propagate errors. Watch out: v-for key pitfalls (index breaks when prepending) and refs are not reactive so use props/events, and use $nextTick to wait for DOM before reading newly rendered elements.
AI-written summary · about
chapters (17)
- 0:00Introduction
- 1:10What is the cue Lifecycle?
- 1:48Lifecycle Hooks
- 2:42beforeCreate
- 3:13created
- 4:28beforeMount
- 6:13mounted
- 7:39beforeUpdate
- 8:07updated
- 9:09beforeDestroy
- 9:38destroyed
- 9:54errorCaptured
- 11:06Keep Alive Components
- 12:16activated
- 12:48deactivated
- 13:21Other pieces of the Vue instance
- 19:20Thank you!
related talks
32mVue.js 입문자가 실무에서 주의해야 할 5가지 특징
25mCommon Mistakes in Vue.js and How to Avoid Them
31mCommon Mistakes in Vue and Nuxt and How to Avoid Them
38mAn Introduction to the Vue Ecosystem
35mCommon Mistakes in Vue.js and How to Avoid Them
27mCommon Mistakes in Vue.js
32mAnimating Vue
55mWhat is a Vue Component
