From 0fd3fadbba954eef6ef3608ee41b6621d94747e5 Mon Sep 17 00:00:00 2001 From: Sven Parker Date: Sat, 2 Jun 2018 11:45:14 +0200 Subject: [PATCH 1/2] Added details about Lifecycle Hooks Mostly a clarification for beginners without prior knowledge about what Lifecycle hooks are. Makes it easier to understand when perhaps only knowing that the developer has a `mounted()` hook. I left out the function syntax because of generality. Add if it makes more sense to add. I am not fully knowledgable in Vue yet. --- src/v2/style-guide/index.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/v2/style-guide/index.md b/src/v2/style-guide/index.md index 035f5a3163..4bffc4a2c1 100644 --- a/src/v2/style-guide/index.md +++ b/src/v2/style-guide/index.md @@ -1514,6 +1514,14 @@ This is the default order we recommend for component options. They're split into 9. **Events** (callbacks triggered by reactive events) - `watch` - Lifecycle Events (in the order they are called) + - `beforeCreate` + - `created` + - `beforeMount` + - `mounted` + - `beforeUpdate` + - `updated` + - `beforeDestroy` + - `destroyed` 10. **Non-Reactive Properties** (instance properties independent of the reactivity system) - `methods` From a5deecd0aff44dd9a744b86344e006764573f359 Mon Sep 17 00:00:00 2001 From: Chris Fritz Date: Sat, 2 Jun 2018 23:38:13 -0400 Subject: [PATCH 2/2] add (de)activated to lifecycle hooks list in style guide --- src/v2/style-guide/index.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/v2/style-guide/index.md b/src/v2/style-guide/index.md index 4bffc4a2c1..15dfb12b21 100644 --- a/src/v2/style-guide/index.md +++ b/src/v2/style-guide/index.md @@ -1520,6 +1520,8 @@ This is the default order we recommend for component options. They're split into - `mounted` - `beforeUpdate` - `updated` + - `activated` + - `deactivated` - `beforeDestroy` - `destroyed`