mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-14 10:04:05 +00:00
23 lines
338 B
Vue
23 lines
338 B
Vue
<template>
|
|
<div>
|
|
<p v-if="$fetchState.pending">
|
|
Fetching...
|
|
</p>
|
|
<pre v-else>{{ team }}</pre>
|
|
</div>
|
|
</template>
|
|
|
|
<script>
|
|
export default {
|
|
async fetch () {
|
|
this.team = await fetch('/team.json').then(res => res.json())
|
|
},
|
|
data () {
|
|
return {
|
|
team: []
|
|
}
|
|
},
|
|
fetchOnServer: false
|
|
}
|
|
</script>
|