图片样本:
示例代码
Vue.use(VueTables.ClientTable);
new Vue({
el: "#food_data",
data: {
columns: ['no', 'name', 'effect', 'cook', 'ingre', 'ingre2'],
tableData: getData(),
options: {
headings: {
no: '#',
name: 'Recipe Name',
effect: 'Buff effect',
cook: 'Cook',
ingre: 'ingredient',
ingre2: 'ingredient'
}
}
}
});
function getData() {
return [
{
no: "1",
name: "Rookie Meat Steak",
effect: "MaxHP+60, MaxSP+6, DEF+8",
cook: "Luxury Worktop",
ingre: "ANY:Meat"
]
}
<body>
<h1 class="remember">Ragnarok mobile <a id ="headdeco">Cook Recipe</a></h1>
<div id="food_data">
<v-client-table :data="tableData" :columns="columns" :options="options" class="table"></v-client-table>
</div>
<script src="index.js"></script>