pccomponentes/ddd
Mini framework PHP para construir aplicaciones con DDD + CQRS + Event Sourcing, orientado a la escritura. Propone arquitectura hexagonal (Application/Domain/Infrastructure/EntryPoint/Util) y guía de capas, dependencias y persistencia basada en eventos.
EntryPoint for dependency injection).AggregateRoot, DomainEvent classes).Orders, Payments as separate domains).EventStoreDB).For Executives: *"This package lets us build scalable, maintainable Laravel apps using Domain-Driven Design—the gold standard for complex systems. Think of it as Laravel’s answer to microservices, but without the orchestration headache. For [Product X], it could:
Domain layer (no more scattered Eloquent models).For Engineers: *"This is a DDD/ES framework-in-a-box for Laravel. Key wins:
Model::update() with domain events (e.g., OrderPaid, InventoryReserved). Enables:
OrderAggregate) and read models (e.g., OrderView) evolve independently.AggregateRoot handles invariants (e.g., ‘order total must match line items’).CommandBus routes HTTP requests to domain logic.
Tradeoff: More boilerplate upfront, but long-term maintainability wins. Start with a single bounded context (e.g., Payments)."*For Architects: *"This addresses three critical pain points in Laravel monoliths:
Order with calculateTotal()) instead of dumb data containers.PaymentGateway).How can I help you explore Laravel packages today?