-
Notifications
You must be signed in to change notification settings - Fork 797
UI: support inlay hints (parameter hints) #1631
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
The language server protocol does not yet have support for this behavior -- see microsoft/language-server-protocol#956. |
The upstream issue (LSP support) is waiting for the inlayHints VS Code API to be finalized (microsoft/vscode#16221). |
The VS Code API has been finalized: microsoft/vscode#16221 (comment). |
Is there an issue already at https://github.com/golang/go/issues? |
As soon as LSP spec is finalized, we can start working on adding that to
|
@hyangah Hello, VSCode 1.65 the inlay hints api was finalized :-) |
any news on this feature? |
Change https://go.dev/cl/410132 mentions this issue: |
Change https://go.dev/cl/411094 mentions this issue: |
Change https://go.dev/cl/410974 mentions this issue: |
Change https://go.dev/cl/411100 mentions this issue: |
Change https://go.dev/cl/411102 mentions this issue: |
Change https://go.dev/cl/411101 mentions this issue: |
This change implements support for textDocument/inlayHint and adds inlay hints for parameter names. For golang/go#52343. For golang/vscode-go#1631. Change-Id: I3f989838b86cef4fd2b4076cb6340010fff7c24c Reviewed-on: https://go-review.googlesource.com/c/tools/+/411094 gopls-CI: kokoro <[email protected]> Reviewed-by: Hyang-Ah Hana Kim <[email protected]> Reviewed-by: Suzy Mueller <[email protected]> Run-TryBot: Jamal Carvalho <[email protected]> TryBot-Result: Gopher Robot <[email protected]>
For golang/go#52343. For golang/vscode-go#1631. Change-Id: I94a1b3c389d8bfaa48754e28a52ef76c29eb6ead Reviewed-on: https://go-review.googlesource.com/c/tools/+/411100 Run-TryBot: Jamal Carvalho <[email protected]> gopls-CI: kokoro <[email protected]> TryBot-Result: Gopher Robot <[email protected]> Reviewed-by: Hyang-Ah Hana Kim <[email protected]> Reviewed-by: Suzy Mueller <[email protected]>
For golang/go#52343. For golang/vscode-go#1631. Change-Id: Iaef0beab2837502f6428767f457d1da21848fcb6 Reviewed-on: https://go-review.googlesource.com/c/tools/+/411101 Run-TryBot: Jamal Carvalho <[email protected]> TryBot-Result: Gopher Robot <[email protected]> Reviewed-by: Suzy Mueller <[email protected]> gopls-CI: kokoro <[email protected]>
For golang/go#52343. For golang/vscode-go#1631. Change-Id: I8fba5ddf0bd25ba0fc20f3305ce13868f426087c Reviewed-on: https://go-review.googlesource.com/c/tools/+/411102 Run-TryBot: Jamal Carvalho <[email protected]> TryBot-Result: Gopher Robot <[email protected]> Reviewed-by: Suzy Mueller <[email protected]> gopls-CI: kokoro <[email protected]>
From @zombiezen:
It looks like Javascript/Typescript have similars, e.g. |
Change https://go.dev/cl/413678 mentions this issue: |
Change https://go.dev/cl/413679 mentions this issue: |
Users can configure inlay hints through the go config. Omitting these settings to prevent duplicate values. For #1631. Change-Id: I4ce10154210b1dc4ba34734a3aa3644b22349134 Reviewed-on: https://go-review.googlesource.com/c/vscode-go/+/413679 TryBot-Result: kokoro <[email protected]> Run-TryBot: Jamal Carvalho <[email protected]> Reviewed-by: Hyang-Ah Hana Kim <[email protected]> Reviewed-by: Suzy Mueller <[email protected]>
Adding the inlay hint settings to the go configuration allows for toggling inlay hints from settings.json or the settings UI. For #1631. Change-Id: Iccf2ff3db89d195f694883403d4a25160d66e7ff Reviewed-on: https://go-review.googlesource.com/c/vscode-go/+/413678 Reviewed-by: Hyang-Ah Hana Kim <[email protected]> Run-TryBot: Jamal Carvalho <[email protected]> TryBot-Result: kokoro <[email protected]>
@hyangah I saw a release notes for support of inlay hints, but at least in my case that seems to not work: Also nothing changed in IDE. I always take |
@n-r-w that's interesting, these config params work, however, according to https://github.com/golang/vscode-go/blob/master/docs/settings.md configuration should be done in general |
The go.* params work in vscode-go nightly and configuration is available in the UI at Go > Inlay Hints. |
Change https://go.dev/cl/417295 mentions this issue: |
v0.35.0 released today has dedicated settings for inlay hints. Please use |
Hello vscode-go team,
Can you please try to make the vscode-go extension support parameter name hints in the upcoming version ? :)
Example of similar support at the moment is the extension https://marketplace.visualstudio.com/items?itemName=DominicVonk.parameter-hints which started supporting parameter name hints with TypeScript 4.4.
It would be perfect to see have this feature available through vscode-go extension if the editor has API for it. thanks
The text was updated successfully, but these errors were encountered: