Skip to content

laurentkempe/BlazorApp-OLD

Repository files navigation

BlazorApp

Experimenting with Blazor WebAssembly RC, Continuous integration using Github Actions and hosting on Github Pages! See the result on https://laurentkempe.com/BlazorApp/

.NET Core

Visual Studio Code

Visual Studio Code Learn more

For sure you need the C# extension, but I guess you already have it, then you need JavaScript Debugger (Nightly) - Learn more and enable it in Visual Code settings of the extension:

Enable JavaScript Debugger (Nightly)

To hit a break point, you need to launch the app with the two launcher created " .NET Core Launch (Blazor Standalone)" then ".NET Core Debug Blazor Web Assembly in Chrome"

breakpoint

Build using Github Actions

See the configuration build.yml. It is the default configuration provided by Github, just modify the .NET Core Version to 3.1.201!

It works!

Github Actions build

Host on Github Pages

Create a docs folder on your Github repository and set the configuration like this

Github Pages configuration

Then locally I ran

dotnet publish -c Release

and copied the results to the docs folder and followed the blog post, "Hosting Blazor WebAssembly app on GitHub Pages"

I've got the following issue

Blazor integrity issue

So, I followed the recommendation of @SteveSandersonMS on this Github issue, and added

<BlazorCacheBootResources>false<BlazorCacheBootResources>

Pushed the change to Github and you can see the result here - https://laurentkempe.com/BlazorApp/

Releases

No releases published

Packages

No packages published