This project shows how to easily reuse Blazor UI and code across multiple web and hybrid projects.
- Blazor WebAssembly hosted (Client + Server) (Web)
- Blazor Server (Web)
- .NET MAUI + BlazorWebView (Windows, MacOS, iOS, Android)
- WPF + BlazorWebView (Windows)
- Windows Forms + BlazorWebView (Windows)
- WinUI 3 + unofficial BlazorWebView (Windows 10/11) - Credits: w-ahmad/BlazorWebView.WinUI3, dotnet/maui#7380.
- Photino.Blazor (Windows, MacOS, Linux)
For AvaloniaUI please see MicroSugarDeveloperOrg/Avalonia.WebView and MicroSugarDeveloperOrg/Avalonia.BlazorWebView.Sample for now (note: they are not fully compatible with .NET 8 yet).
- Clone this repo
git clone github.com/manfromarce/BlazorEverywhere
- Put most of your code can be put in the BlazorShared project which is referenced by all other projects
- Build and run the desired targets. You can remove projects that you don't need.
Some sample code is already present, mainly to show how to mix native controls and Blazor and how to use JavaScript interop.