In my .vue file, I have the following code snippet:
<template>
<button @click="entries.push(3)">
Press me!
</button>
<ul>
<li v-for="entry in entries" :key="entry">
{{ entry }}
</li>
</ul>
</template>
<script setup>
const entries = [1, 2]
</script>
When I click the button, I expect a third li
element to be added but nothing happens. What could be causing this issue?