frontend/components/timelines/Public.vue
2024-04-27 19:02:27 -10:00

16 lines
435 B
Vue

<template>
<TimelinesTimeline :timeline="timeline" :load-next="loadNext" :load-prev="loadPrev" />
</template>
<script lang="ts" setup>
const client = useMegalodon();
const timelineParameters = ref({});
const { timeline, loadNext, loadPrev } = usePublicTimeline(
client.value,
timelineParameters,
);
useListen("note:delete", ({ id }) => {
timeline.value = timeline.value.filter((note) => note.id !== id);
});
</script>