Created
December 10, 2019 05:13
-
-
Save coltborg/02347c0baab51a793c597a15077b5eb3 to your computer and use it in GitHub Desktop.
Vue 3 Essentials - Lifecycle hooks
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script> | |
import { onBeforeMount, onMounted } from "vue"; | |
export default { | |
setup() { | |
onBeforeMount(() => { | |
console.log("Before mount!"); | |
}); | |
onMounted(() => { | |
console.log("Mounted!"); | |
}); | |
} | |
}; | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment