I can t seem to get why the Blazor Server Web runs with a 404 when I try to move Components/Pages and Components/Layouts from the default Blazor Server Web project to a new RCL project. Everything is at default, .NET 8.0 is used, and one thing I picked up from tutorials is to add AdditionalAssemblies to the Router:
<Router AppAssembly="@typeof(Program).Assembly" AdditionalAssemblies="new[] {typeof(ComponentLib.Components.Layout.MainLayout).Assembly, typeof(ComponentLib.Components.Pages.Home).Assembly}">
<Found Context="routeData">
<RouteView RouteData="@routeData" DefaultLayout="@typeof(MainLayout)"/>
<FocusOnNavigate RouteData="@routeData" Selector="h1" />
</Found>
</Router>
Otherwise I have no idea why the 404, I tried moving the Pages dir to the root of RCL project, I tried setting copy-always for the pages and the layout files. When I "return/copy" the Components/Pages and Components/Layouts to the Blazor Web project, everything is back to normal, Hello World is displayed.