Managed vs Unmanaged Code (Garbage Collection) in C#
Managed and unmanaged code are two types of code that differ in how they handle memory management. In this article, we'll explore the differences between managed and unmanaged code, focusing on garbage collection. Blazor Server and Blazor WebAssembly often...
How to Build Dynamic Queries With Expression Trees in C#
Applications are becoming more complex and data-driven over time. Indeed, developing the ability to create and modify dynamic queries at runtime is becoming a critical skill for developers. In this article, we'll explore the basics of building dynamic query expression...
How to Send Emails With the SendGrid API in C#
In this article, we will take a look at how to send emails with the SendGrid API directly from our code. Sending emails from within our applications is a common scenario that we face as developers. Let's look at a couple of use cases where we may need to do this. .NET versions can be confusing, especially if you're new to .NET. Take...
How to Map DateOnly and TimeOnly Types to SQL
In this post, we are going to learn how to map DateOnly and TimeOnly types to SQL with migration. Let's dive in. DateOnly and TimeOnly Types...
Using System.Text.Json for Camel Case Serialization
In this article, we'll learn how to use System.Text.Json for camel case serialization in .NET 7. First, we'll take a glance at the default behavior when serializing. Then we'll use two different ways for the camel case serialization. Lastly, we'll discuss how we can...
How to Generate Permutations in C#
In this article, we will examine the world of algorithms. Specifically, we will talk about an algorithm that we can use to generate permutations. ...
Swashbuckle vs. NSwag in ASP.NET Core
In this article, we will explore the two popular libraries for generating OpenAPI documentation in C#: Swashbuckle and NSwag. We'll compare their features, ease of use, and other factors that will help us choose the best one for our projects. [sc name="github"...
Different Ways to Initialize a String in C#
In this article, we will discuss how we can initialize a string in C# and the recommended best practices to follow. We will explore different approaches and techniques that enable us to achieve proper initialization and efficient utilization of strings. [sc...
How to Convert Stream to Byte Array in C#
In this article, we are going to learn how to convert a stream to a byte array in C#. A Stream represents a continuous...