keyof generic doesn't work in template
Vue version
^3.3.0
Link to minimal reproduction
Steps to reproduce
No steps required. You should be able to see the highlighted typescript error around line 5. Similar to this one:
What is expected?
As you can see the expected behavior can be seen in the childrenCount function. The childrenCountKey prop expects a valid object key so its ussage within the template should be very straighforward
What is actually happening?
The template does not accept childrenCountKey as a valid node object key
System Info
System:
OS: Windows 10 10.0.22621
CPU: (8) x64 AMD Ryzen 7 4700U with Radeon Graphics
Memory: 2.78 GB / 15.37 GB
Binaries:
Node: 18.17.0 - C:\Program Files\nodejs\node.EXE
Yarn: 1.22.19 - C:\Program Files\nodejs\yarn.CMD
npm: 7.24.2 - C:\projects\xamu\ui\node_modules\.bin\npm.CMD
Browsers:
Edge: Spartan (44.22621.2283.0), Chromium (117.0.2045.43)
Internet Explorer: 11.0.22621.1
npmPackages:
vue: ^3.3.4 => 3.3.4
Any additional comments?
No response
Similar to #9277. See also vuejs/language-tools#3204. Changing the usage of props
to $props
in volar virtual files may resolve this problem
Should be fixed by https://github.com/vuejs/core/pull/9418