Skip to content

Feature slice

A feature slice is the migration unit below a DDD layer and bounded context. One slice carries domain rules, application behavior, adapter mapping, interface binding, orchestration, contract proof, and colocated tests without becoming a top-level architecture root.

Feature code stays under its DDD layer and bounded context:

domain/<bounded_context>/features/<feature>/
application/<bounded_context>/features/<feature>/
adapters/<bounded_context>/features/<feature>/
interfaces/<bounded_context>/features/<feature>/
orchestration/<bounded_context>/features/<feature>/

Top-level features/, flat source-era layer folders such as domain/settlement, and direct sibling-feature implementation imports are not allowed. Feature collaboration uses an explicit public contract or port. See ADR 029.