effect-layers-services

Define service interfaces and bind live/test implementations through layers.

Updated Nov 20, 2025
One-click install
npx skills add https://github.com/mepuka/adjunct --skill effect-layers-services
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: effect-layers-services
Source: https://github.com/mepuka/adjunct/tree/main/.claude/skills/effect-layers-services
Command: npx skills add https://github.com/mepuka/adjunct --skill effect-layers-services

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Defining services, providing layers, and composing dependencies for robust app structure and testability.

Core Features & Use Cases

  • Define Service interfaces
  • Provide Layer bindings (live/test)
  • Compose layers for scalable DI boundaries

Quick Start

Define a service, create a Live layer, and provide it at the app boundary.

Frequently Asked Questions about effect-layers-services

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

FAQPage Schema
How do I set up dependency injection with live and test service implementations?

Dependency injection with swappable implementations uses service layers to bind live and test versions at app startup. Define service interfaces, create Live and Test layers that provide concrete implementations, and compose them at your app boundary. This lets you switch between environments without code changes.

What's the best way to structure services for testability?

Structure services by defining clear interfaces, then provide implementations through dependency injection layers. Separate live implementations (database, HTTP clients, loggers) from test doubles in distinct layers. This boundary makes tests predictable and fast while keeping production code unchanged.

How do I compose multiple service layers in an application?

Compose layers by declaring service interfaces, creating provider layers for each environment (live, test), and combining them at your app's entry point. Each layer binds concrete implementations to interfaces. The composition establishes your app-wide infrastructure boundaries for loggers, databases, and HTTP clients.

Can I use service layers to swap between live and test configurations?

Yes. Service layers enable environment-aware provision through swappable bindings. Define a service interface once, provide live implementation in production and test doubles in tests, then pass the appropriate layer to your app. No code duplication or environment-specific logic needed.

When should I apply dependency injection boundaries?

Apply DI boundaries when building scalable apps requiring infrastructure components like loggers, databases, and HTTP clients. Service layers work best for app-wide composition where you need predictable testing, clear separation of concerns, and the ability to swap implementations across environments.