Life cycle hooks are methods that let us alter the behavior of components at various stages of their life cycle.
Lifecycle hooks
What is a component's lifecycle?
It's just the natural progression of the life of a component.
Thus, we can say that lifecycle hooks are points along this journey that each component needs to go through. At these specific points in a component's life, we can use these methods to alter a component's behavior.
The Vue team has chosen very descriptive names for these lifecycle methods. What follows is the list of lifecycle hooks organized in the order of the natural progression of a component's life:
- beforeCreate
- created
- beforeMount
- mounted
- beforeUpdate
- updated...