False ts(6133) error message
Issue:
VSCode with latest Volar (1.8.8) complains about values that are declared and never read if values are used inside template with v-else of v-else-if.
Reproduction:
- Clone this repo: https://github.com/KamilBeda/nuxt-vs-code-typescript-bug
- Install dependencies
- Open app.vue and look at the error at
doSomethingfunction
Temporary fix:
Reverting Volar to 1.8.7
A "minimal" reproduction: https://play.vuejs.org/#eNp9kTFPwzAQhf+KdawlGbqVFAlQBxgAAaOXkF5CimNb9jlEqvLfOTskgFTYnPe+u7xnH+HK2qwPCBsofOVaS8IjBStUqZutBPISLqWTujLak6iNEVtBLuBFFIt8mklEEgg7q0rCpAhR3JjOfp35a3ZFf97WcTsvkiDO4tr8JIbK48QyE9HX0i1okS/ri/zXn2HFyTly3TbZwRvN9Y5xQkLFE61C92Cp5UoSNiI50SuVMh93SYvJVrNevWH1fkI/+CFqEh4denQ9d1k8Kl2DNNm753sc+LyYndkHxfQ/5hN6o0LMOGHXQe859g8upb3trHHU6ubF7wZC7edS6WqZHBMvgd84XtZf1b/jrrN1mpN6hPETGbyzIA==
Reverting to 1.8.7 does not solve this problem :(
For me it does but it intruduced Vue language server crashes so I reverted to 1.8.6 and everything seems to work fine now
Interesting, when volar parses the code, the AST node of the second slot is totally lost!
Opened https://github.com/vuejs/core/pull/11150, which may solve this issue.
This one seems to be fixed