lunasqu.ee-nuxt/pages/blog/index.vue

15 lines
321 B
Vue

<template>
<NuxtLayout name="blog">
<template v-for="post of posts">
<BlogPost :post="post" :detail="false" />
</template>
</NuxtLayout>
</template>
<script setup lang="ts">
const { data: posts } = await useFetch('/api/blog', {
key: 'frontpage',
params: { limit: 16, render: false },
});
</script>