Hey, I'm Steven a .NET Developer and Freelancer in Zurich, Switzerland. I am a Microsoft MVP.
Also, this blog is open source on GitHub.

Recent Posts

Preview image blogpost

The state machine in C# with async/await

You often here that the async/await keywords leads to a state machine. But what does that mean? Let's discuss this with a simple example.

Read the whole article

Preview image blogpost

How not to benchmark!

I came across a recent LinkedIn post about the let statement in LINQ and it's performance implication. And in typically influencer fashion it out right claimed that using let in LINQ is a bad idea and should be avoided. But is it a bad idea?

Read the whole article

Codespaces for your open-source project

In this blog post, I will show you how to use GitHub Codespaces to make it easier for contributors to get started on your open-source project. We will set up a codespace for a .NET repository and configure it to install the required dependencies and tools.

Read the whole article

Preview image blogpost

ReadOnlySet<T> in .NET 9

The next preview (preview 6) will bring a new type ReadOnlySet<T>. This is a read-only set that is similar to ReadOnlyCollection<T>. Let's see how it works and why it was introduced.

Read the whole article

Preview image blogpost

NCronJob - June Edition

The last update of NCronJob was some time ago - and as always, there are some new features in the meantime. So here we are, let's go through to highlight them!

Read the whole article

Preview image blogpost

Are my EF LINQ to SQL queries safe?

Have you ever asked yourself if your EF LINQ queries are susceptible to SQL injection attacks? Either because you are querying some user data from a text field or directly taking whatever your API hits against the database?

Read the whole article

Preview image blogpost

Does an HttpClient await the Header and the body?

If you call HttpClient.GetAsync or HttpClient.PostAsync and then await the result, does the await wait only for the headers to be received or does it wait for the body to be received? Let's find out!

Read the whole article

StringBuilders magic for very large strings

The StringBuilder class is used to create mutable sequences of characters. Strings are immutable, so if you need to perform multiple operations on a string, it is better to use a StringBuilder instead of a string. This is especially useful when you need to concatenate a large number of strings. But there is more magic to it, especially when we go BIG!

Read the whole article

Preview image blogpost

Cancel WhenAny - linked CancellationTokenSource

In today's short post, I will show you how to cancel a Task with multiple inputs (aka multiple CancellationTokens) using CancellationTokenSource and CancellationTokenSource.CreateLinkedTokenSource.

Read the whole article

An error has occurred. This application may no longer respond until reloaded. Reload x