locked
Mixing Blazor Server with Blazor WebAssembly RRS feed

  • Question

  • User-1618157774 posted

    When creating a server based blazor app is it still possible to use client-side features of the blazor ?

    to be more clear: let's say we want to execute most of requests server-side but some features client-side (C# only code), is it possible too achieve this in the server based hosting model?

    Monday, December 2, 2019 10:52 AM

All replies

  • User2041008840 posted

    Both Are Different Platforms 
    If you want to build SPA go with Blazor Server You cannot mix both

    Thursday, March 19, 2020 2:41 AM
  • User-1813699890 posted

    Hi johnbalj,

    it's not possible to mix the functionalities of the two hosting models in the same project. 

    Instead, you can make a solution with a Blazor Server-Side as a back-end and a Blazor WebAssembly as a front-end communicating each other via API. You can take a look to the Blazing Pizza sample made by Steve Sanderson.

    Friday, July 3, 2020 6:21 AM
  • User379720387 posted

    I also suggest that you look at blazing pizza: https://github.com/dotnet-presentations/blazor-workshop

    It is a nine part part tutorial that is well documented, plus each part has a .sln that you can open up in case you messed something up.

    There is also the blazor boilerplate that you can look at: https://blazorboilerplate.com

    Some functionality is client side.

    Friday, July 3, 2020 3:18 PM