Nuxt/test/fixtures/basic/components/AsyncServerComponent.server.vue

21 lines
349 B
Vue
Raw Permalink Normal View History

<template>
<div>
This is a .server (20ms) async component
{{ data }}
<div id="async-server-component-count">
{{ count }}
</div>
<Counter :multiplier="1" />
<slot />
</div>
</template>
<script setup lang="ts">
defineProps<{
count: number
}>()
const { data } = await useFetch('/api/very-long-request')
</script>