What problem does it solve?
This Skill ensures C# code adheres to established naming conventions, formatting rules, and modern language features, leading to more readable, maintainable, and consistent codebases.
Core Features & Use Cases
- Naming Conventions: Enforces PascalCase for public members and camelCase for private members.
- Code Formatting: Ensures consistent use of braces, spacing, and avoids magic numbers.
- Modern C# Features: Promotes the use of expression-bodied members,
var, pattern matching, and null-conditional operators.
- Documentation: Guides on using XML documentation comments for public APIs.
- Async/Await: Provides best practices for asynchronous programming, including naming and
ConfigureAwait.
- Use Case: When writing or reviewing C# code for a .NET project, this skill will provide guidance on how to structure classes, name methods and variables, and utilize modern C# syntax for better code quality.
Quick Start
Apply the csharp-standards skill to ensure the provided C# code follows best practices for naming and formatting.