I'm trying to style my data in Vuejs, I want every property to be vertical. every item in conversationHistory should be vertical not on the same line. how can I do that in vuejs? anyone can help?
<template>
<h2 class="Email">Messages</h2>
<div v-if="messages?.conversationHistory" >
{{ messages.conversationHistory[0].action }}
{{ messages.conversationHistory[0].messageId }}
{{ messages.conversationHistory[0].attachments }}
{{ messages.conversationHistory[0].body }}
{{ messages.conversationHistory[0].from }}
{{ messages.conversationHistory[0].to }}
{{ messages.conversationHistory[0].cc }}
{{ messages.conversationHistory[0].subject }}
{{ messages.conversationHistory[0].sent }}
</div>
</template>
<script>
import axios from 'axios';
export default {
name: 'message-api',
data(){
return{
messages: null,
}
},
created() {
axios.get(`http://sa-test-task-2022.s3-website.eu-north-1.amazonaws.com/messages`)
.then(response => {
// JSON responses are automatically parsed.
this.messages = response.data
})
.catch(e => {
this.errors.push(e)
});
}
}
</script>