Circular component import breaks types #5059
Labels
bug
Something isn't working
good reproduction ✨
This issue provides a good reproduction, we will be able to investigate it first
🔨 p3-minor-bug
Vue - Official extension or vue-tsc version
2.1.10
VSCode version
2.1.10
Vue version
3.5.13
TypeScript version
5.6.3
System Info
package.json dependencies
Steps to reproduce
src/components/List.vue
What is expected?
v-model:open="isOpen"
:isOpen
is expected to be of typeboolean
emit('branch:click')"
:emit
is expected to be typedWhat is actually happening?
isOpen
is of type{}
emit
is of type{}
Link to minimal reproduction
https://github.com/gu-stav/vue-tsc-circular-reproduction
Any additional comments?
As soon as you remove
<Sublist @branch:click="() => emit('branch:click')" />
,isOpen
is properly typed:I was not able to reproduce it, but in our app the above works until we upgrade from:
"vue-tsc": "^2.1.6", "typescript": "^5.5.4",
to"vue-tsc": "^2.1.10", "typescript": "^5.6.3"
The text was updated successfully, but these errors were encountered: