[Vuejs]-How do you detect all child components of a given route have rendered in Vue.js?

0👍

If I understand your question I think you could send an event to the root instance from the child whenever the updated hook is called in the child.

Example:

Child:

<div>Hello</div>
<script>
export default {
 updated: {
   this.$emit("render")
 }
}
</script>

Root:

<child v-on:render="onChildRender">
<script>
export default {
  methods: {
    onChildRender() {
      console.log("child rendered")
    }
  }
}
</script>

Hopefully, this helps.

Leave a comment