Closed MohanDrey24 closed 2 months ago
It's weird. it works fine in playground
It's weird. it works fine in playground
so this issue is caused by nuxt perhaps? because i noticed this issue in our production app when we updated from vue 3.4+ to 3.5+ and nuxt 3.12.4 to nuxt 3.13.0
I believe this is a known issue with Nuxt: https://github.com/nuxt/nuxt/issues/28829.
@MohanDrey24 For now you can U can do like this: https://github.com/nuxt/nuxt/issues/28829#issuecomment-2329411615
Vue version
3.5.3
Link to minimal reproduction
https://stackblitz.com/edit/nuxt-starter-yaazew?file=components%2FVInput.vue,app.vue,package.json
Steps to reproduce
When pressing the toggle button in app.vue, the type doesn't change at all even though the props is supposedly reactive (Vue 3.5.3 + Nuxt 3.13.1) https://stackblitz.com/edit/nuxt-starter-yaazew?file=components%2FVInput.vue,app.vue,package.json
In Vue 3.4.38 + Nuxt 3.13.1, the type changes whenever i press the toggle button meaning it still retains reactivity https://stackblitz.com/edit/nuxt-starter-w6nfak?file=app.vue,components%2FVInput.vue
I found out that by removing the default value of the destructured props in Vue 3.5.3 + Nuxt 3.13.1, it will become reactive again but in Vue 3.4.38 + Nuxt 3.13.1, it doesn't loses it's reactivity even with a default value.
What is expected?
I expected the VInput component prop type to toggle from text to password and vice versa whenever we press the toggle button
What is actually happening?
It doesn't change the prop type of the VInput component
System Info
Any additional comments?
No response