Spokane .NET Conference: MVVM in Blazor WASM with the Community Toolkit

Поделиться
HTML-код
  • Опубликовано: 31 янв 2025

Комментарии • 11

  • @GraGra3333
    @GraGra3333 Год назад +6

    So glad to see that someone has found and shared a simple MMVM solution for Blazor!

  • @rasmustchristensen
    @rasmustchristensen Год назад +5

    Great example of getting started with Blazor and MVVM Toolkit, thanks!

  • @Tb69420
    @Tb69420 Год назад +1

    Thank you! Now I can confidently use Blazor!

  • @mazmazik3022
    @mazmazik3022 Год назад +2

    What about navigation from the view model? I found that blazors NavigationManager can only work if injected in to razor component. If injected to any other class it throws an exception. Is there a way to handle navigation by from the view model? For example I want to on button click execute a command that calls some service and then navigates me to another page.

    • @abidmehmoods
      @abidmehmoods 8 месяцев назад

      Any update on this?

    • @oclockvnwithcode
      @oclockvnwithcode Месяц назад +1

      it's a bit late but if anyone still looking for the answer, we can create an interface and inject it to the vm, then in the implementation of the interface (which we put in client project), inject NavigationManager and implement methods for navigation

  • @kungfutommy
    @kungfutommy Год назад

    This looks great! How would I go about injecting services in through the constructors of the view models?

  • @rogersteinbakk
    @rogersteinbakk Год назад +2

    MVVM toolkit is great. Can this be useful for Blazor server as well, or only for WASM?

    • @IntelliTect
      @IntelliTect  Год назад +1

      Hi @rogersteinbakk, I reached out to Kelly, the presenter, with your question! This is what he said, "Hmmm, I haven't tried it with Blazor Server, I guess theoretically it would work, but sending all that Observable state back and forth over the internet seems like it would be slow."

    • @rogersteinbakk
      @rogersteinbakk Год назад

      @@IntelliTect Thanx for responding! :)

  • @alexdobrynin
    @alexdobrynin Год назад

    what if we have more complex data, for example nested complex objects in which also smth changes. how does mvvmcomponentbase know about it?