My JSON Array has the following structure:
items: [
{
ID: 11,
UserID: "test.com",
UserRole: "user",
timeStamp: "2021-03-23T15:54:02.125578",
dialogs: [
{
"Bot": "Why is data missing?",
"test.com": "not available",
"Bot": "please enter ID",
"test.com": "1234"
}
]
}
]
I need to display elements inside dialogs as a list. I am using v-for, but dialogs are being displayed as an array with commas. How can I show this with an index? Here is the v-for loop I am using:
<ul v-for="item in items" :key="item">
<li v-for="(dialog, index) in dialogs" :key="index">{{ key }}: {{ dialog }}</li>
</ul>