vuejs-challenges icon indicating copy to clipboard operation
vuejs-challenges copied to clipboard

12 - Optimize performance directive

Open zhang13pro opened this issue 2 years ago • 0 comments

// your answers
<script setup>
import { ref } from "vue"

const count = ref(2)

setInterval(() => {
  count.value++
  console.log(count.value) 
}, 1000)
</script>

<template>
  <span v-once>Make it never change: {{ count }}</span>
</template>

zhang13pro avatar Sep 21 '22 02:09 zhang13pro