WPF Blazor app - MC3050 Cannot find the type 'local:Index'. #49422
-
Hi, I've been following the Build a Windows Presentation Foundation (WPF) Blazor app with .NET 8 preview 6 and Visual Studio 17.7 preview 3 and am stumped by this error I've been getting: I have a reproducible GitHub repo and I'd be super grateful if anyone's able to take a look or knows off-hand why I'd be getting this error because I'm stuck at the moment. Is it a source generator thing? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
the EDIT: Real root problem was that I was using |
Beta Was this translation helpful? Give feedback.
the
@code
section in the.razor
file needs to be moved to a codebehind.razor.cs
or it won't be foundEDIT: Real root problem was that I was using
<Project Sdk="Microsoft.NET.Sdk">
instead of<Project Sdk="Microsoft.NET.Sdk.Razor">
.