I created a .NET 9 Blazor MAUI Hybrid Web application using the new template with WebAssembly as the render mode. I wanted to add Identity authentication, so I took the Login.razor, Register.razor, etc., Blazor components from a web application project and placed them into the .Web project. The screens load fine and work (user is able to login, register etc.), but I’m encountering this error:
ManagedError: One or more errors occurred. (Root component type 'MyApp.Web.Components.Account.Login' could not be found in the assembly 'MyApp.Web'.
From my research, I’m unsure if this issue is caused by placing the Razor components into the .Web project instead of the .Client or .Shared projects. However, the components depend on the Microsoft.AspNetCore.Identity.UI NuGet package, which causes build errors when added to the .Shared or .Client projects.
I'm out of ideas what is the issue.