Inferred useTemplateRef
type is incorrect when used in v-for
#5320
Labels
good reproduction ✨
This issue provides a good reproduction, we will be able to investigate it first
Vue - Official extension or vue-tsc version
2.2.4
VSCode version
1.99.2
Vue version
3.5.13
TypeScript version
5.4.5
System Info
package.json dependencies
Steps to reproduce
Component1.vue
Component2.vue
components
type is incorrect:[email protected]
and see that thecomponents
type is correct (it correctly infers an array):Note:
This seems to only be an issue when placing the ref inside of the slot. Placing it on the root
v-for
element seems to work correctly:What is expected?
I expect the type to correctly infer an array of elements and/or components. See: Refs inside v-for
What is actually happening?
The type infers a single element and/or component instead of an array.
Link to minimal reproduction
No response
Any additional comments?
No response
The text was updated successfully, but these errors were encountered: