Nuxt/examples/composables/use-async-data/components/MountainExample.vue

10 lines
213 B
Vue
Raw Permalink Normal View History

<script setup>
const { data: mountain } = await useFetch(
'https://api.nuxtjs.dev/mountains/mount-everest'
)
</script>
<template>
<pre class="text-sm text-left overflow-auto">{{ mountain }}</pre>
</template>