JSFiddle - React, Tailwind, and code Playground
by Nightythehawk
HTML
<div id="Itemlist">
<table class="table">
<tr>
<th>Username</th>
<th>User</th>
</tr>
<tr v-for="item in items">
<td>{{item.username}}</td>
<td>{{item.user}}</td>
</tr>
</table>
</div>
Vue
var ItemsVue = new Vue({
el: '#Itemlist',
data: {
items: []
},
mounted: function () {
var self = this;
$.ajax({
url: 'https://jsonplaceholder.typicode.com/users',
method: 'GET',
success: function (data) {
self.items = data;
}
});
}
});