Aspnetcore: Blazor app routing error on adress bar | Github Pages

Created on 15 Jun 2020  ·  4Comments  ·  Source: dotnet/aspnetcore

Hello,

https://zafer-v3.github.io/TurkishLiraHistory -> I can access this

https://zafer-v3.github.io/TurkishLiraHistory/fetchdata -> I can't acess directly sub adress.

I dont know why.

Describe the bug

A clear and concise description of what the bug is.

To Reproduce

Exceptions (if any)

Further technical details

  • ASP.NET Core version
  • Include the output of dotnet --info
  • The IDE (VS / VS Code/ VS4Mac) you're running on, and it's version
Answered Resolved area-blazor blazor-wasm question

All 4 comments

@zafer-v3 thanks for contacting us.

I believe this is a limitation of deploying to a static site. GH doesn't know anything about client-side routes so it doesn't server index.html and only does that on the root page.

I try azure web sites and run cool than github pages :)

https://dollarsallary.azurewebsites.net/fetchdata

@zafer-v3 You might want to check this example of a Blazor WebAssembly app on GitHub pages which works with deep linking (sub-addresses).

Internally the solution is https://github.com/rafrex/spa-github-pages

I think Github teams solve this.

Was this page helpful?
0 / 5 - 0 ratings