We are going to continue working with the story examples from the previous chapter, using the slightly improved paginated API. So, we are going to modify the code, to be able to access and use the data.
If you take a look at the code from the previous example you will see that our fetchStories
method is similar to this:
new Vue({ ... methods: { ... fetchStories: function () { var vm = this; this.$http.get('/api/stories') .then(function (response) { var storiesReady = response.data.map(function (story) { story.editing = false; return story }) vm.$set('stories', storiesReady) }); }, ... } });
If we open our HTML file on the browser, as you may have already guessed, our table doesn't...