You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a component that takes two type parameters, one of which is constrained using the second as a type parameter of the constraint. If, in the component usage on a razor component, the type parameters are specified in the opposite order that they are on the component where they are used, VS shows an error in the UI, but builds correctly. I see no warnings or errors in the build, Rider doesn't complain, and the code works correctly, so seems to me like a VS tooling issue.
Changing the order of the type params so that they match what is defined in the component fixes the error
I have a component that takes two type parameters, one of which is constrained using the second as a type parameter of the constraint. If, in the component usage on a razor component, the type parameters are specified in the opposite order that they are on the component where they are used, VS shows an error in the UI, but builds correctly. I see no warnings or errors in the build, Rider doesn't complain, and the code works correctly, so seems to me like a VS tooling issue.
Changing the order of the type params so that they match what is defined in the component fixes the error

This only happens if the component has an
@bind
applied as well (as far as I can tell). A minimal repro (based on the .net 8 blazor web app template) is available here: https://github.com/mmesdag/RazorTypeParameterOrderingError.Component with type params:
Type param constraint:
Type used in component usage
The text was updated successfully, but these errors were encountered: