Best of C#April 2024

  1. 1
    Article
    Avatar of ardalisArdalis·2y

    5 Rules for DTOs

    Learn the 5 rules for DTOs, including their purpose, ease of use, property usage, naming conventions, and specific use cases.

  2. 2
    Article
    Avatar of towardsdevTowards Dev·2y

    Improving Factory Pattern using DI in .Net

    This post discusses how to improve the Factory Pattern using Dependency Injection in .Net 5. It explains the concept of the Factory Pattern and demonstrates how dependency injection can be used to enhance it.

  3. 3
    Article
    Avatar of csharpcornerC# Corner·2y

    Explain Lambda Functions in .NET C#

    Explore the fundamentals of lambda functions in .NET C#. Learn about their concise syntax, closure capture, and practical applications in LINQ queries, event handling, and asynchronous programming.

  4. 4
    Article
    Avatar of freecodecampfreeCodeCamp·2y

    What is Mocking? Mocking in .NET Explained With Examples

    Learn about mocking in .NET software development, including why it's necessary for building a robust testing strategy and exploring popular mocking libraries. Gain the knowledge to choose the best mocking tool for your needs.

  5. 5
    Article
    Avatar of codemazeCode Maze·2y

    How to Build a URL Shortener in .NET Applications

    Learn how to build a URL shortener in .NET using the ASP.NET Core Web API framework.

  6. 6
    Article
    Avatar of vscodeVisual Studio Code·2y

    Visual Studio Code Day 2024

    VS Code Day 2024 is a 2-day event focused on learning and enhancing development workflow with Visual Studio Code. The event will cover topics like AI-powered programming with GitHub Copilot, building generative AI apps, and enhancing the C# development experience. The hosts of the event are Reynald Adolphe and Gwyneth Peña-Siguenza.

  7. 7
    Article
    Avatar of csharpcornerC# Corner·2y

    New LINQ Methods in .NET 9 Preview

    Discover the new LINQ methods in .NET 9 Preview and learn how to use CountBy, AggregateBy, and Index for grouping items, finding the most frequent word, and extracting index positions in a list.

  8. 8
    Article
    Avatar of milanjovanovicMilan Jovanović·2y

    Introduction to Distributed Tracing With OpenTelemetry in .NET

    Learn what OpenTelemetry is and how to use it in .NET applications for distributed tracing. Configure OpenTelemetry with instrumentations and exporters. Run Jaeger locally for analyzing distributed traces.

  9. 9
    Article
    Avatar of codemazeCode Maze·2y

    Invariance, Contravariance, and Covariance in C# Generics

    Exploration of the roles, significance, usage, and impact of invariance, contravariance, and covariance in C# generics programming.

  10. 10
    Article
    Avatar of codemazeCode Maze·2y

    How to Validate a GUID in C#

    Explore several approaches to validate a string representation of a GUID in C#. Learn about the format of a GUID and different techniques like regular expressions, Guid.Parse(), Guid.ParseExact(), Guid.TryParse(), and the Guid constructor for validation. Benchmarking results show that Guid.TryParse() methods offer better performance and efficiency.

  11. 11
    Article
    Avatar of codemazeCode Maze·2y

    Fastest Way to Find and Extract a Number From a String in C#

    Explore the quickest method to find and extract a number from a string in C#. Implement techniques using regular expressions, LINQ, StringBuilder, and Span. Performance comparison shows the advantage of using Span with the lowest memory allocation.