-
Notifications
You must be signed in to change notification settings - Fork 12.5k
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
Enums and interfaces do not have definitions in quick info/tooltips #25894
Comments
Also, if I have interface, which extends another interface:
And I use |
I agree. hovering over a type name to get a pop-up with the same text is rather useless. we can do better. |
Just adding on to this. I find it really annoying that the type information for interfaces and enums are basically useless. It also affects all the IDEs when they display the definitions. See this one for JetBrains IDE's: https://youtrack.jetbrains.com/oauth?state=%2Fissue%2FWEB-44531 |
Could someone point out where in the code base these definitions are created, and especially where the Types one are vs the Interface. Then maybe someone from the community can take a look at actioning this. |
My tactic for figuring out stuff like this is to enable TSServer logging, perform the action you're interested in, then see what requests were made:
So this request is a |
The issue might be related to this one, but mine is not about version 3.0, and is not solely about imports.
Search Terms
enum, description, definition, pop-up, tooltip, vs code, interface, suggestion
Suggestion
Hovering over enums and interfaces, should show their definition, i.e. I have this enum (or an interface):
If I hover over this enum, wherever I use it (whether it is imported to another file or used locally where it is declared), I would like to see what this enum is all about (essentially what are the properties).
This is what I see right now when I hover over enums or interfaces:
As a workaround, I currently need to add this type of JSDoc comments right above the enum declaration.
Which yields to:
Use Cases
This feature would save time & effort.
The shortcoming of the current approach is that either need to add
${2+numberOfEnumProperties} lines
of comments or go to the file, where enum is declared, locate the enum there and then familiarize myself with its properties.Examples
Checklist
I am not that experienced to be able to answer the questions below.
The text was updated successfully, but these errors were encountered: