My goal is to change the row value to 10 when clicking on <textarea>
, and revert it back to 6 if clicked outside of the element. I am new to Vue.js 3 and struggling with this issue, particularly regarding directives.
<template>
<div>
<textarea :rows="row"></textarea>
</div>
</template>
<script>
export default {
data() {
return {
row: 6
}
}
}
</script>