[Vuejs]-I want to called id into sibling component in the axios get method and display the output data in vue client table

0👍

Try this

created () {
   axios.get('http://192.168.2.35:8000/api/v1/post_bi/'+ this.tableDataId)
     .then((response) => {
       this.tableData = response.data;
     })
     .catch((error) => {
       console.log(error)
   })
})

Assuming you have declared tableData and tableDataId in your component like this

data() {
  return {
    tableData: '',
    tableDataId: '',
  }
}

Leave a comment