I am trying to loop through an array and create 2 rows in a table.
Here is my desired output:
<tbody>
<tr>
<td>col 1</td>
<td>col 2</td>
<td>col 3</td>
<td>col 4</td>
</tr>
<tr>
<td colspan="4">col 5 (This is a reall long 4 colspan row..................)</td>
</tr>
However, I seem to be getting stuck with doing this in Vue JS. If I am reading the docs correctly the way to loop through and repeat elements would be to do something like this:
<tr v-for="(data, index) in messages" :key="index">
However, that only accounts for the first tr.
How can I get that loop to account for 2 rows. I considered wrapping the tr in a div but that would not be semantically correct.
Edit: Using template tag.
<template v-for="data in messages">
<tr>
<td>col 1</td>
<td>col 2</td>
<td>col 3</td>
<td>col 4</td>
</tr>
<tr>
<td colspan="4"> col 5</td>
</tr>
</template>
I am now getting two errors on both the tr tags that say
Elements in iteration expect to have 'v-bind:key' directives
When I add that to one, I get an error on the other. When I add it to both I get duplicate key error.

messages? please put an example of them.