Nuxt/test/fixtures/basic/components/SugarCounter.vue
Anthony Fu f69126e8f4
feat: support reactivity transform (#3737)
Co-authored-by: pooya parsa <pyapar@gmail.com>
Co-authored-by: Daniel Roe <daniel@roe.dev>
2022-03-17 23:17:59 +01:00

15 lines
313 B
Vue

<script setup lang="ts">
const { count } = defineProps<{
count: number,
}>()
// eslint-disable-next-line prefer-const
let multiplier = $ref(2)
const doubled = $computed(() => count * multiplier)
</script>
<template>
<div>
Sugar Counter {{ count }} x {{ multiplier }} = {{ doubled }}
</div>
</template>