ddd-clean-architecture

Guide Domain-Driven Design and Clean Architecture layering and dependency direction.

Updated May 2, 2020
One-click install
npx skills add https://github.com/vankichi/dotfiles --skill ddd-clean-architecture-vankichi
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: ddd-clean-architecture
Source: https://github.com/vankichi/dotfiles/tree/main/claude/ja/skills/ddd-clean-architecture
Command: npx skills add https://github.com/vankichi/dotfiles --skill ddd-clean-architecture-vankichi

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill serves as a comprehensive reference for DDD and Clean Architecture practices, providing guidance on proper layer boundaries, dependency direction, Port-Adapter patterns, and other design principles.

Core Features & Use Cases

  • Layered Architecture Guidance: Explains the roles and responsibilities of each layer in DDD + Clean Architecture.
  • Dependency Direction: Outlines the correct dependency direction between layers and components.
  • Port-Adapter Pattern: Describes the implementation of the Port-Adapter pattern for clean separation of concerns.
  • Use Case: This Skill can be used by developers and architects during the design and review phases of software development to ensure adherence to best practices.

Quick Start

Access the skill by typing "ddd-clean-architecture" to view a summary of DDD + Clean Architecture principles and patterns.

Frequently Asked Questions about ddd-clean-architecture

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

FAQPage Schema
What is the correct dependency direction in domain-driven design and clean architecture?

The correct dependency direction in domain-driven design and clean architecture points inward toward the domain layer, ensuring outer layers like infrastructure depend on inner layers without reversing the flow.

How do I implement the Port-Adapter pattern for clean separation of concerns?

To implement the Port-Adapter pattern for clean separation, define interfaces in the application layer and concrete adapter implementations in the infrastructure layer to isolate external dependencies.

What are the roles and responsibilities of each layer in a layered architecture?

In a layered architecture, roles and responsibilities are divided into domain, application, and infrastructure layers, each handling specific business logic and coordination tasks to maintain strict boundaries.

When do I need clean architecture guidance during software development?

You need clean architecture guidance during the design and review phases of software development to ensure proper layer boundaries, validate dependency direction, and enforce domain-driven design principles.

What is the best way to separate concerns using clean architecture and DDD?

The best way to separate concerns using clean architecture and DDD is by enforcing strict layer boundaries, applying the Port-Adapter pattern, and directing dependencies inward toward the domain.

Why does my layered architecture have dependency direction issues during refactoring?

Layered architecture dependency direction issues during refactoring usually occur when outer layers directly reference inner domain components, violating the clean architecture principle of inward dependencies.