Currently, I get no IntelliSense hints for classes that are in 3rd party packages that I have not yet imported with using
.
For example, if i type ConnectionMul
I get no hints, so I have to instead type the entire classname ( ConnectionMultiplexer
) and then type Alt+Enter
and only then does it suggest using StackExhange.Redis
.
I'm used to IntelliJ's hinting with Java. When I have dependencies added to the project, I can just type Con
and it will already have suggestions including the 3rd party classes. Is there a way to do this in Visual Studio?
If you've already referenced the type in your project (via assembly or NuGet package), it should show up as a lightbulb action when you've typed a partial match:
However, it seems that this requires at least 5 charactes typed - when I try it with JObj
I don't get the suggestion, but with JObje
I do.
There are also (for completeness) options under the C# language that suggest using statements from NuGet or the local reference assemblies path once you've typed out the type name:
When this is turned on and you use a type not referenced in your project, you'll see a suggestion like this:
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.