#553 – April 20, 2025
string interpolation, proper collection capacity initialization or stack-allocated memory
Optimizing memory usage with modern .NET features
10 minutes by Nemanja Mijailovic
In this blog Nemanja discusses memory optimization techniques after migrating from .NET Framework to newer versions like .NET 8 and 9. She shares real-world examples of reducing memory allocations through modern approaches such as string interpolation, proper collection capacity initialization or stack-allocated memory. She also emphasizes the importance of addressing verified performance issues rather than prematurely optimizing code.
Null-Conditional Assignment in C#
6 minutes by Arunkumar Gudelli
Arunkumar introduces .NET 10 Preview 3 null-conditional assignment, allowing developers to write expressions that only perform assignments when the target object isn't null. This feature eliminates repetitive null checks, making code more concise and readable while protecting against NullReferenceExceptions. In this post Arunkumar shows you how it works with a simple example.
Building Your First MCP Server with .NET
5 minutes by Engincan Veske
In this practical guide Engincan explains what MCP (Model Context Protocol) is and how it works, how to build your first MCP Server using .NET or how to integrate it with the Cursor code editor.
Understanding GraphQL in .NET: When and why to use it
7 minutes by Ali Hamza Ansari
Ali dives deep into exploring how GraphQL can be a better alternative to RESTful APIs in certain scenarios. He explains that GraphQL allows clients to request customized data responses, eliminating problems like over-fetching or under-fetching that are common with REST APIs. Ali demonstrates this with examples of social media, e-commerce, and IoT applications, then provides a step-by-step guide for implementing GraphQL in ASP.NET Core using the HotChocolate framework.
Debugging htmx in ASP.NET Razor Pages: Tips, Tricks, and Tools
4 minutes by Chris Woodruff
Dive into debugging HTMX requests and responses like a pro. In this article Chris provides a troubleshooting guide for developers using htmx with ASP.NET Razor Pages, covering common issues like incorrect endpoints, missing targets, wrong HTTP methods, and improper response formats. It details debugging techniques including browser DevTools, htmx debug mode, error handling with hx-on:error, and server log checking, with practical code examples of a comment system to illustrate proper implementation.
And the most popular article from the last issue was: