[Vuejs]-How To run a function in Vuejs after the component in created?

0👍

It looks fine.
As @a-lau says, make sure the parent is updating the catalogselected prop

Btw, you can write your watcher this way and remove completely the created hook:

watch: {
  catalogselected: {
    handler: "GetItemsToShowonMainPage",
    immediate: true
  }
}

If you still have issues you might want to write a minimal reproduction on https://codesandbox.io/s/vue

Leave a comment