[Vuejs]-V-for loop in vuejs doesn't return anything

0👍

You have declared app variable but its not defined. replace app variable with this e.g

created(){
        let _this = this
        axios.get(this.bUrl1 + '/api/getMessages')
          .then(response => {
            _this.privsteMsgs = response.data; //we are putting data into our posts array
            console.log(_this.privsteMsgs);
          })
          .catch(function (error) {
            console.log(error); // run if we have error
          });

      }

Leave a comment