Implements use cases for C# and Blazor (.NET 10) applications using a Vertical Slice Architecture. Takes a UC-XXX.md specification and generates feature-folder components, C# Commands/Queries, EF Core entities/configurations, and Blazor pages/components. Use when the user asks to "implement a use case in C#", "build a Blazor page", "create a Vertical Slice", or mentions Blazor, .NET 10, or C# implementation.
67
80%
Does it follow best practices?
Run evals on this skill
Adds up to 20 points to the overall score
View guide
Passed
No findings from the security scan
Implement the specified use case (UC-XXX.md) in a C# and Blazor application following Vertical Slice Architecture principles.
A diff of the specification change may follow the file path in the arguments. When it is there, it is the definitive list of what changed — work through it change by change. A removed line is an instruction to delete the behaviour it described: the remaining specification is already satisfied by the existing code, so a removal is invisible unless you compare code to spec in both directions.
Before writing any code, check whether this use case is already implemented — look for a
Features/UCXXX_<FeatureName>/ folder, and search for the page, command/query, handler, and entity
names the spec implies. If an implementation exists, reconcile it with the specification instead
of building a parallel one:
.razor markup)Read Specifications & Design Requirements:
docs/use_cases/UC-XXX-*.md.docs/requirements.md to extract relevant Non-Functional Requirements (NFRs), UI/UX design constraints (C-XXX), styling/theme directives, color palettes, and accessibility requirements.docs/entity_model.md.docs/vision.md if additional visual identity or brand guidelines are needed.Vertical Slice Folder Structure:
Features/UCXXX_<FeatureName>/.UCXXX_Page.razor (Blazor UI component template)UCXXX_Page.razor.cs (Code-behind logic)UCXXX_Page.razor.css (Scoped CSS styles for rich UI aesthetics)UCXXX_Command.cs or UCXXX_Query.cs (Request payload)UCXXX_Handler.cs (Use case execution logic / EF Core operations)UCXXX_Validator.cs (Validation rules using FluentValidation or Data Annotations)C# & Blazor Guidelines (.NET 10):
namespace MyApp.Features.UC001;).required properties, pattern matching, collection expressions []).@rendermode InteractiveServer or @rendermode InteractiveAuto for interactive Blazor components as required by project conventions, or Static SSR (@attribute [StreamRendering]) for read-heavy pages.[Inject] or @inject).IDbContextFactory<AppDbContext> or delegate data access to transient/scoped MediatR or command handlers to prevent DbContext concurrency exceptions.CancellationToken from Blazor component events and lifecycle methods to async handlers.UI Design & Styling Standards:
docs/requirements.md. Avoid raw unstyled HTML elements.UCXXX_Page.razor.css or integrate with global CSS design tokens (wwwroot/app.css).DO NOT:
.razor markup files — delegate to handlers or code-behind .razor.cs.DbContext directly into interactive Blazor components — use IDbContextFactory or handler abstraction instead.bunit-test and dotnet-test skills).Template Boilerplate Cleanup & Navigation:
dotnet new blazor boilerplate sample pages (Counter.razor, Weather.razor) and their links from NavMenu.razor when implementing initial features.Components/Layout/NavMenu.razor (or project navigation layout) using styled NavLink elements matching the app theme.Compilation Verification:
dotnet build to verify clean compilation.Next Step Guidance:
"Next step: Run
/bunit-testto write component UI tests, or/dotnet-testto write backend integration tests, followed by/playwright-testto generate end-to-end browser tests."
c3a5da3
If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.