domain-architecture

Enforce domain-driven architecture by separating domain services, server actions, and route components.

Updated Apr 8, 2026
One-click install
npx skills add https://github.com/notilmi/portofun --skill domain-architecture-notilmi
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: domain-architecture
Source: https://github.com/notilmi/portofun/tree/main/.agents/skills/domain-architecture
Command: npx skills add https://github.com/notilmi/portofun --skill domain-architecture-notilmi

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Enforces domain-driven architecture with a clear separation between domain services, server actions, and route components to reduce coupling and increase maintainability.

Core Features & Use Cases

  • Enforces Domain Layer separation (domain/services), server actions, and UI components with explicit boundaries and naming conventions.
  • Provides structured guidelines for schemas, errors, and service patterns to sustain single-responsibility, testability, and predictable evolution.
  • Offers concrete examples of file organization and interaction patterns across domain, server, and UI layers for scalable projects.

Quick Start

Apply these guidelines to structure a new project by creating domain services, schemas, and server actions according to the documented patterns.

Frequently Asked Questions about domain-architecture

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

FAQPage Schema
How do I separate domain services from server actions and UI components?

To separate domain services from server actions and UI components, enforce domain-driven architecture with explicit boundaries and naming conventions. Define inputs, schemas, and errors upstream so components and actions follow documented single-responsibility patterns.

What is the best way to structure a scalable domain-driven project folder?

The best way to structure a scalable domain-driven project is creating dedicated domain services, schemas, and server actions according to documented patterns. Apply concrete file organization examples across domain, server, and UI layers to maintain predictable evolution.

How do I organize schemas and error handling for domain services?

Organize schemas and error handling for domain services by defining them upstream in the domain layer. Apply structured guidelines for schemas, errors, and service patterns to sustain testability and single-responsibility across server actions and route components.

When do I need domain-driven architecture for my application?

You need domain-driven architecture when reducing coupling and increasing maintainability across domain services, server actions, and UI components becomes critical. It sustains scalable, maintainable code by ensuring inputs, schemas, and errors follow documented patterns.

Can I apply single-responsibility patterns to existing server actions and route components?

Yes, you can apply single-responsibility patterns to existing server actions and route components by enforcing explicit boundaries and naming conventions. Ensure inputs, schemas, and errors are defined upstream and that actions follow the documented service patterns.