<template>
<router-link
class="event-link"
:to="{ name: 'EventDetails', params: { id: event.id } }"
>
<div class="event-card">
<span>@{{ event.time }} on {{ event.date }}</span>
<h4>{{ event.title }}</h4>
</div>
</router-link>
</template>
<script lang="ts">
import { defineComponent, PropType } from 'vue'
import { EventItem } from '../types'
export default defineComponent({
props: {
event: {
type: Object as PropType<EventItem>,
required: true
}
}
})
</script>