Closed scottwillmoore closed 1 year ago
@orta This seems to have been a regression in version 1.2.0.
Previously //^? comments worked as expected in VSCode in WSL Ubuntu.
After, I'm seeing a lot of incorrect results that seem to be the same root cause as those @scottwillmoore described. I'm confused about all the inlay hints stuff as that seems unrelated to me, but this version does seem to be broken at the moment.
Yeah, this seems like a bug with the lookup code changes in https://github.com/orta/vscode-twoslash-queries/pull/23 to me 👍🏻
I just installed the extension, but it doesn't appear to show the correct type when there are no new lines between types.
In this example, the wrong type is displayed next to each of the types.
However, when new lines are added the issue is resolved.
TypeScript version:
5.1.3
. Visual Studio Code version:1.79.2
. Extension version:1.2.0
.I have inlay hints shown when I hold
Ctrl + Alt
.EDIT(1): Shouldn't the TypeScript language server implement inlay hints for type definitions. I couldn't find an option in my Visual Studio Code settings, and I couldn't find any relevant issues on the TypeScript repository. I guess I should raise my own issue?
EDIT(2): To clarify, I did find your issue to upstream this extension. However, couldn't TypeScript just support
type A /* = false */ = IsNumber<undefined>;
in a similar manner that it works for parameters, variables, etc. The twoslash query is not required, but could still be provided by this extension.