Instead of using eval, You can write the code by calling a function from HTML, and in the field you can write a function, which will determine what will be the output.
in Html:
<tr v-for="(item, index) in myitems">
<td v-for="column in mycolumns" v-text="myFunc(index, column.field)">
</td>
</tr>
in Vue Component:
mycolumns: [
{
column: "Todo Name",
field: (item) => item.name
},
{
column: "Status",
field: (item) => item.status
},
{
column: "Status Explanation",
field: (item) => item.status == 1 ? 'Done' : 'Todo'
}
]
},
methods:{
myFunc(index, fn){
return fn(this.myitems[index])
}
}
check working fiddle.
However this does not seem to be very good practice, as now your data is tightly bind to your html. So your container component and presentation container are not independent, can not grow independently and are error prone as well.