home / skills / duc01226 / easyplatform / create-feature

create-feature skill

/.claude/skills/create-feature

This skill scaffolds a full-stack feature in C# projects, outlining domain, CQRS, API, and optional Angular frontend scaffolding.

npx playbooks add skill duc01226/easyplatform --skill create-feature

Review the files below or copy the command above to add this skill to your agents.

Files (1)
SKILL.md
1.6 KB
---
name: create-feature
description: "[Implementation] Scaffold a new feature with backend and frontend components"
infer: true
---

Create a new feature: $ARGUMENTS

## Steps:

1. **Analyze Requirements**
   - Break down the feature requirements
   - Identify the scope (backend only, frontend only, or full-stack)

2. **Identify Service Location**
   - Determine the appropriate microservice for backend
   - Identify the Angular app/module for frontend

3. **Plan Implementation**
   - Domain entities needed
   - CQRS Commands/Queries
   - API endpoints (controllers)
   - Angular components and services
   - DTOs and validation

4. **Use Platform Patterns**
   - Reference patterns from CLAUDE.md
   - Use `.github/prompts/` templates for scaffolding:
     - `create-cqrs-command.prompt.md`
     - `create-cqrs-query.prompt.md`
     - `create-entity-event.prompt.md`
     - `create-angular-component.prompt.md`
     - `create-api-service.prompt.md`

5. **Wait for Approval**
   - Present the implementation plan
   - **DO NOT proceed without explicit approval**

6. **Create Files (After Approval)**
   Execute in this order:
   1. Domain entities (`.Domain/Entities/`)
   2. Application layer (`.Application/UseCaseCommands/`, `.Application/UseCaseQueries/`)
   3. Entity DTOs (`.Application/EntityDtos/`)
   4. API controllers (`.Api/Controllers/`)
   5. Frontend components and services

7. **Verify**
   - Build backend: `dotnet build`
   - Build frontend: `nx build <app-name>`

## IMPORTANT Task Planning Notes

- Always plan and break many small todo tasks
- Always add a final review todo task to review the works done at the end to find any fix or enhancement needed

Overview

This skill scaffolds a new feature with both backend and frontend components, producing a clear implementation plan and the files needed to implement it. It guides the developer through requirement analysis, service identification, CQRS planning, API and Angular component design, and verification steps. The skill enforces an approval gate before file creation to avoid premature changes.

How this skill works

It inspects the feature arguments and breaks them into discrete tasks: determine scope (backend, frontend, or full-stack), select the target microservice and Angular module, and plan domain entities, CQRS commands/queries, DTOs, controllers, and UI components. It references platform patterns and scaffolding templates to generate consistent prompts for each artifact. After you approve the plan, it generates files in the recommended order and includes build verification steps.

When to use it

  • Introducing a new domain feature that requires backend logic and a UI update
  • Adding CRUD operations that should follow CQRS and domain-driven patterns
  • Scaffolding a small-to-medium feature across microservice and Angular app
  • When you need a consistent starting plan before implementation begins
  • Preparing work that will be handed off to other developers or reviewers

Best practices

  • Break the feature into many small, actionable TODO tasks, including a final review task
  • Identify the authoritative microservice and the Angular module before designing artifacts
  • Follow CQRS separation: write commands for state changes and queries for reads
  • Use the provided scaffolding templates to keep patterns consistent across features
  • Stop and present the implementation plan for explicit approval before creating files

Example use cases

  • Add a new Product aggregate with create/update/delete operations and an admin UI
  • Implement a read-heavy reporting endpoint with optimized queries and a dashboard panel
  • Scaffold a user preferences feature that includes profile DTOs, validation, and settings UI
  • Introduce an event-driven entity with domain events and corresponding API endpoints
  • Create a microservice API and an Angular form plus service to consume it

FAQ

What templates are used for scaffolding?

Use the .github/prompts/ templates like create-cqrs-command.prompt.md and create-angular-component.prompt.md to generate consistent scaffolding prompts.

Do files get created immediately?

No. The skill requires explicit approval of the implementation plan before generating files and making changes.