razor icon indicating copy to clipboard operation
razor copied to clipboard

Blazor Intellisense doesn't work in razor page for this specific condition

Open vsfeedback opened this issue 3 years ago • 1 comments

This issue has been moved from a ticket on Developer Community.


When the class name is the same as the @inject something ClassName

for this case @inject IChatHub ChatService

I don't get any suggestions for the interface methods which is annoying when working with big interface. And I don't like using lowercase for the inject name.

It only does this in razor components.

image


Original Comments

Feedback Bot on 8/18/2022, 11:22 PM:

(private comment, text removed)

Mackinnon Buck [MSFT] on 8/19/2022, 10:40 AM:

(private comment, text removed)

Jihad Khawaja on 8/19/2022, 10:48 PM:

(private comment, text removed)


Original Solutions

(no solutions)

vsfeedback avatar Aug 25 '22 21:08 vsfeedback

Have asked about this on VS Feedback, because I think that this could be a C# compiler thing, where the word "ChatService" could mean either a type or a member, and the compiler doesn't know until you provide more code. This is known as the "Color Color" problem.

davidwengier avatar Aug 26 '22 04:08 davidwengier

This appears to be working in 17.13 released builds, after a year of changes that potentially impacted it. Please let us know if you run into this in 17.13 and higher builds.

phil-allen-msft avatar Mar 10 '25 16:03 phil-allen-msft