Host a blazor server app

Hey @nirjhar18 :wave:t2:

Typically when folks talk about building a “Blazor” app, they’re talking about a streamed-interactivity app where there’s an active, running server (running your .NET back end) and a connected front end that streams content and interactions between the two. It’s a …complicated setup.

You can also create a client-side-only Blazor app. I haven’t done it myself (been out of the .NET game a couple years), but from what I understand, this would allow you to export / publish a static site from your project that uses Blazor’s conversion to WebAssembly to produce a fully static site. Theoretically, this would work on Netlify.

Since Netlify supports Homebrew in the build image, you could theoretically get your build to run your Dotnet build then have Netlify publish the correct output directory… but I saw this all without ever having tested that personally.

This tutorial may help you get started with building a client-site-only Blazor app (e.g. static site). You’d just need to add a netlify.toml file to your repository and correctly configure the build and publish fields. Oh, and a brewfile per the announcement above.

I hope that helps

–
Jon