[Vuejs]-Laravel-False response in axios inside vue.js

1👍

already know the problem, instead of using single quotes I use backticks

created(){
        axios.get(`/posts/heart-status/${this.postId}`)
        .then(response =>{
            console.log(response.data.isHeart)
            this.isFilled = response.data.isHeart;
        })
        .catch(function (error) {
          console.error(error);
        })
    },

Leave a comment