Nuxt/test/fixtures/basic/components/islands/PureComponent.vue
Daniel Roe ab125bd1c5
feat(nuxt): experimental server component islands (#5689)
Co-authored-by: Pooya Parsa <pooya@pi0.io>
2022-11-24 13:24:14 +01:00

27 lines
444 B
Vue

<script setup lang="ts">
const props = defineProps({
bool: Boolean,
number: Number,
str: String,
obj: Object
})
const hasRouter = useState('hasRouter', () => !!useRouter())
</script>
<template>
<div>
Was router enabled: {{ hasRouter }}
<br>
Props:
<!-- eslint-disable-next-line vue/no-v-html -->
<pre v-html="JSON.stringify(props, null, 2)" />
</div>
</template>
<style scoped>
pre {
color: blue
}
</style>