Microsoft .NET Source Generators

Source Generators were introduced in .NET 5 and provide a powerful way to not only generate code but also improve performance. This post will show, by example, how to use the source generators in Microsoft .NET.