Skip to content

Serving server-side blazor from subfolder #8953

@yevhen

Description

@yevhen

Using server-side rendered Blazor, I moved Pages and Components folder into GUI subfolder. I also changed <_RazorComponentInclude>Components\**\*.cshtml</_RazorComponentInclude> to <_RazorComponentInclude>GUI\Components\**\*.cshtml</_RazorComponentInclude>. Then compiling and running the app (F5 from VS19) shows blank screen (localhost page not found). The Index.cshtml is not served.

To Reproduce

Steps to reproduce the behavior:

  1. Using the latest VS19 preview create the ASP.NET Core Web Application with Razor Components
  2. Move Pages and Components folders into GUI subfolder
  3. Fix namespaces to be able to compile and run the app
  4. Change blazor-related property in csproj file to <_RazorComponentInclude>GUI\Components\**\*.cshtml</_RazorComponentInclude>
  5. Compile and run the app
  6. See the error

Not sure whether it's a bug or is there something I miss which need to be additionally configured?

Metadata

Metadata

Assignees

No one assigned

    Labels

    DocsThis issue tracks updating documentationarea-blazorIncludes: Blazor, Razor Componentsquestion

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions