0👍
For HTTP requests, you should use the Vue Resource library:
https://cdnjs.cloudflare.com/ajax/libs/vue-resource/0.1.3/vue-resource.min.js
Then you can write the code like this:
<div v-repeat="etsyData">
...
</div>
var vue = new Vue({
el: '#app',
data: {
apiUrl: "........",
etsyData: {}
},
ready: function(){
this.$http.get(this.apiUrl, function(data, status, request){
this.etsyData = data;
})
}
})
You’ve put the number 42 in your v-repeat
instead of the actual vue property.
If you insist on using jquery instead, then you have to access the vue object from the outside, like this: vue.etsyData = data
, or if the data object is in side a component, it will be something like this: vue.$children[0].etsyData = data
.
Source:stackexchange.com