I don't understand why it is working when I am passing an anonymous function to the @input field of my html input component, but it is not working when i am calling instead a real function with the exact same code inside. Here is the code when it is not working:

```
<script setup>
import { ref } from 'vue'

const text = ref('')
const numberChar = ref(0)
const numberWords = ref(0)

function count() {
    numberChar = text.length
    numberWords = text.split(' ').filter((e) => e != '').length
}

</script>

<template>

<div class="box">
<input v-model="text" placeholder="Write here" @input="count"/>
 <p>
     Text : {{text}} <br>
     Characters : {{numberChar}} <br>
     Words : {{numberWords}}
 </p>
</div>

</template>

```

but when I am simply putting this :

```
<input v-model="text" placeholder="Write here" @input="() => numberChar = text.length"/>

```

the numberChar value is correcttly modified and displayed.
I am starting Vuejs so I am missing something but it's been an hour I am struggling with this...