ReadOnlyCollection is not an immutable collection
Explains the difference between ReadOnlyCollection and truly immutable collections in C#, showing how underlying data can still change.
Steven Giesel is a Senior Software Engineer and Microsoft MVP with over 13 years of experience, specializing in .NET and modern backend development. He shares deep technical knowledge across topics such as C#, EF Core, RavenDB, distributed systems, and cloud-native architectures, and is an active speaker in the .NET community.
311 articles from this blog
Explains the difference between ReadOnlyCollection and truly immutable collections in C#, showing how underlying data can still change.
Explores the pitfalls of using public const in C#, explaining compile-time replacement and versioning issues, and suggests using static readonly instead.
A tutorial on creating a reusable modal dialog component using Bootstrap in a Blazor application.
Explores four methods for creating arrays in C#, comparing performance and use cases for new, ArrayPool, GC.AllocateArray, and GC.AllocateUninitializedArray.
Explains the difference between default(MyStruct) and new MyStruct() in C# 10, highlighting that default bypasses parameterless constructors.
A technical guide on building a fully automated CI/CD pipeline using GitHub Actions, DocFx, and .NET to test, build, release, and document with one click.
Explains the differences between struct, readonly struct, ref struct, and record struct in C#, focusing on usage, limitations, and memory management.
A guide to creating a low-allocation, faster StringBuilder alternative in C# using Span<T> for improved performance in string concatenation.
A tutorial on creating a reusable loading bar component in Blazor using C#, Bootstrap, and data binding with INotifyPropertyChanged.
Final part of a UNO Platform tutorial series, implementing drag-and-drop functionality and state persistence for a Todo app.
Part 4 of a tutorial series on building a Todo app with the UNO Platform, focusing on adding created items to a view model collection.
A technical guide explaining the Trie data structure, its implementation in C#, and its advantages for autocomplete and search operations.
Part 3 of a tutorial series on building a Todo app with the UNO Platform, focusing on creating a dialog component for user interaction.
Part 2 of a tutorial series on building a Kanban-style Todo app using the UNO Platform for cross-platform development.
A tutorial on building a cross-platform Kanban-style Todo application using the UNO Platform with C# and XAML.
A guide to using SIMD (SSE) instructions in C# to optimize performance, demonstrated by summing a list of integers.
Explains the Decorator Pattern in C# using a cached repository example to add behavior dynamically without subclassing.
A tutorial on creating a custom RequiredIf validation attribute for conditional form validation in Blazor applications.
Explains how to use Directory.Build.props to centralize and manage common MSBuild configurations across multiple C# projects.
Explains how to use DebuggerTypeProxy and DebuggerDisplay attributes in C# to control how complex objects appear in the debugger.