I am passing multiple objects
from laravel
to vue
and want to populate my vue objects with values given from the database.
The data from laravel:
Vue objects:
storeName: {},
storeUrl: {},
appName: {},
price: {},
share: {},
Where the data comes:
mounted() {
axios.get('/dashboard/affiliates')
.then(res => {
let data = res.data;
this.storeName = data.affiliates.shop_name;
console.log(data.affiliates);
})
As I understand, one of the bests ways would be to populate my vue objects it would be with filter function of javascript, but quite don't get it fully and don't know how to do it.
How could I populate vue objects with data that later on I could list them to the view in a v-for?
from Newest questions tagged laravel-5 - Stack Overflow https://ift.tt/3hSeJKC
via IFTTT
Aucun commentaire:
Enregistrer un commentaire