Less boilerplate code with the new primary constructor in C# 12
Explains how C# 12's new primary constructor feature reduces boilerplate code, especially in Dependency Injection scenarios.
Explains how C# 12's new primary constructor feature reduces boilerplate code, especially in Dependency Injection scenarios.
Explores .NET 8's new UnsafeAccessorAttribute for faster, AOT-friendly reflection, comparing it to traditional methods with benchmarks.
A guide to creating and testing custom JsonConverter classes in C# using System.Text.Json, including helpful extension methods for unit tests.
Explores the concept of discriminated unions in C#, their implementation using generic Results classes, and their application in ASP.NET Core Minimal APIs.
A tutorial on building a minimal clone of ASP.NET Core from scratch to understand its core concepts like the web server, controllers, and middleware.
A humorous C# tutorial solving Fizz Buzz with exceptions, Polly retry policies, and C# 12 features, demonstrating intentionally 'dumb' code.
Explains how to create a ChunkedList<T> in C# to avoid Large Object Heap issues when storing massive amounts of data.
Explains the benefits and practical use of C# nullable reference types for safer code and cleaner API design.
Explains how to accurately measure Unicode string lengths in C# using the StringInfo class, addressing challenges with non-ASCII characters in console output.
Explains the memory leak issue with C# events and demonstrates how to implement the Weak Event pattern using weak references.
Introducing MiniWord, an open-source .NET library for generating Word documents from templates using OpenXML and C#.
Explains the difference between auto-property initializers and expression-bodied getters in C#, showing how each affects property value evaluation.
Analyzes how C and C++ compilers' handling of undefined behavior prioritizes performance, often at the cost of program correctness and predictability.
Explains unexpected behavior of C#'s Enum.TryParse method and provides a solution using Enum.IsDefined for validation.
Introducing Sisk, a lightweight, open-source, and cross-platform alternative HTTP server for .NET, independent of ASP.NET Core.
A quick reference guide for developers transitioning from the Moq mocking library to NSubstitute, covering syntax comparisons.
Explains the advantages of creating custom fakes for unit testing in C#/.NET instead of relying on third-party mocking libraries like Moq.
The Moq library faces controversy for using SponsorLink, a tool that checks for GitHub sponsorships during builds, raising privacy and open-source concerns.
Explains the new Keyed Services feature in .NET 8 Preview 7, showing how to register and inject named dependencies.
A tutorial on implementing Clean Architecture principles in Blazor WebAssembly applications using C#, .NET, and WebAssembly.