dotnet-shared

Define shared domain models to eliminate duplication across Backend and Frontend projects.

Updated Nov 30, 2025
One-click install
npx skills add https://github.com/gabrielsan90/FacturacionV2 --skill dotnet-shared
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: dotnet-shared
Source: https://github.com/gabrielsan90/FacturacionV2/tree/main/.claude/skills/dotnet-shared
Command: npx skills add https://github.com/gabrielsan90/FacturacionV2 --skill dotnet-shared

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Define and reuse a shared domain model layer to eliminate duplication across Backend and Frontend projects.

Core Features & Use Cases

  • Shared domain entities, DTOs, enums, and ActionResponse that can be consumed by multiple projects.
  • Consistent validation annotations and data contracts across Backend and Frontend.
  • Use case: centralize models for a common domain like users, orders, and status codes to ensure uniform behavior.

Quick Start

Add shared domain models and data contracts in the [ProjectName].Shared project and reference them from Backend and Frontend to ensure consistency.

Frequently Asked Questions about dotnet-shared

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I share domain models and DTOs between backend and frontend .NET projects?

To share domain models and DTOs, define them in a dedicated shared layer project and reference it from both backend and frontend. This eliminates duplication and enforces consistent entities, enums, and response contracts across layers.

How do I enforce consistent validation annotations across API and UI layers in .NET?

Consistent validation annotations are enforced by placing data annotations on shared DTOs in a centralized project. Referencing this shared layer from API and UI layers ensures both compile-time nullable reference checks and uniform validation behavior.

What is the best way to structure separate DTOs for create, read, and update operations in .NET?

The best way to structure DTOs for create, read, and update is to define separate data contracts within a shared domain layer. This approach enforces lightweight mappings between domain entities and DTOs while maintaining strict boundary contracts.

Do I need a shared layer to eliminate entity duplication across multiple .NET projects?

You need a shared layer to eliminate entity duplication when multiple projects require consistent domain models. Centralizing entities, DTOs, and enums in a shared project ensures compile-time consistency and uniform behavior across consumers.

Can I centralize response contracts and enums for a common domain like users and orders in .NET?

You can centralize response contracts and enums by defining a shared domain model layer. This includes ActionResponse contracts and domain enums for users and orders, ensuring uniform behavior and data consistency across API and UI projects.