Работа с JSON в Vue js
Подскажите пожалуйста, почему ничего не выводит.
<template>
<div class="hello">
<h3>Timetable</h3>
<li v-for="lesson in data" v-bind:key="lesson.id">
{{lesson.id}} {{lesson.timeOfLesson}}
</li>
</div>
</template>
<script>
import {AXIOS} from "../http-common";
export default {
name: 'HelloWorld',
data: function () {
return{
data: []
}
},
methods: {
loadLesson(){
AXIOS.get('timetable/all')
.then(responce => {
this.data = responce
})
.catch(error =>{
console.log('ERROR' + error.responce.data)
})
}
},
mounted() {
this.loadLesson();
}
}
</script>
JSON
Timetable
{
"data": [{
"id": 1,
"timeOfLesson": "2020-02-17 23:52:22"
}, {
"id": 2,
"timeOfLesson": "2020-02-17 23:52:35"
}, {
"id": 3,
"timeOfLesson": "2020-02-17 23:52:55"
}],
"status": 200,
"statusText": "",
"headers": {
"content-type": "application/json"
},
"config": {
"url": "timetable/all",
"method": "get",
"headers": {
"Accept": "application/json, text/plain, */*"
},
"baseURL": "http://localhost:8080",
"transformRequest": [null],
"transformResponse": [null],
"timeout": 0,
"xsrfCookieName": "XSRF-TOKEN",
"xsrfHeaderName": "X-XSRF-TOKEN",
"maxContentLength": -1
},
"request": {}
}