You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I think the reason for this bug is that defineProps has the wrong type when destructuring. When using reactivity transform, the variable deconstructed by defineProps should be of type ReactiveVariable<T> rather than T. Because of this reason, the type of $$() is wrong.
The text was updated successfully, but these errors were encountered:
Since the value you pass in is not a "reactive variable", "$$" function will think that you are trying to deconstruct array.
e.g. const [fooRef, barRef] = $$([reactiveFoo, reactiveBar])
Vue version
3.2.35
Link to minimal reproduction
https://github.com/xiafrog/unft/blob/master/src/components/Scan/Tx/Table.vue
Steps to reproduce
In line 25, use the original ref of
data
as the parameter ofuseTxTable
. The type of$$(data)
is error.What is expected?
The type of
$$(data)
should beRef<Tx[]>
.What is actually happening?
The type of
$$(data)
actually beRef<Tx>[]
.System Info
Any additional comments?
I think the reason for this bug is that
defineProps
has the wrong type when destructuring. When using reactivity transform, the variable deconstructed bydefineProps
should be of typeReactiveVariable<T>
rather thanT
. Because of this reason, the type of$$()
is wrong.The text was updated successfully, but these errors were encountered: