---
title: "Discussion on \"MVVM Source Generators: Advanced Scenarios\" | Hashnode"
description: "Discussion on \"MVVM Source Generators: Advanced Scenarios\". Intercept property setters and say goodbye to writing busy flags"
url: "https://hashnode.com/posts/mvvm-source-generators-advanced-scenarios/63bbe459c8ae53670b9324d6"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [MVVM Source Generators: Advanced Scenarios](https://blog.ewers-peters.de/mvvm-source-generators-advanced-scenarios?utm_source=hashnode&utm_medium=feed)

Intercept property setters and say goodbye to writing busy flags

Jan 9, 2023 · 11 min read · blog.ewers-peters.de  
Read the article

-   [#mvvm](https://hashnode.com/tag/mvvm)
-   [#sourcegenerators](https://hashnode.com/tag/sourcegenerators)
-   [#dotnet](https://hashnode.com/tag/dotnet)
-   [#csharp](https://hashnode.com/tag/csharp)
-   [#viewmodel](https://hashnode.com/tag/viewmodel)

## Written by

[Julian Ewers-Peters](https://hashnode.com/@ewerspej)

@ewerspej · Germany

  
[View profile](https://hashnode.com/@ewerspej)

Mobile App Developer

I am a passionate mobile app and software developer with a focus on C# .NET, Xamarin.Forms and .NET MAUI.

## Responses 1

Markdown supported · ⌘↵ to post

[AthosXtreme](https://hashnode.com/@AthosXtreme)

[Apr 10, 2025](https://hashnode.com/posts/mvvm-source-generators-advanced-scenarios/63bbe459c8ae53670b9324d6/comment/67f724229f8d55cc15f7ccdd)

Hi Julian. For some reason I can´t get fully async, I mean, UI is mostly blocked and any loading spinner either freeze or don't show at all.

Commenting your las code for clarity:

\[RelayCommand\] private async Task PrintAddressAsync() { //UI is blocked and IsRunning is false if (Copies < 1) return;

//This line releases the UI, IsRunning sets to true and it shows the loading spinner await Task.Delay(TimeSpan.FromSeconds(2));

//Now, the UI is blocked again and the spinner is frozen OnPrintAddress?.Invoke(FullAddress); }

The only way to get really async is wrapping everything in Task.Run.

Any thoughts?
