effect-layers-services
Installation
SKILL.md
Layers & Services
When to use
- You need DI boundaries or swapping test/live implementations
- You want to compose infra (logger, db, http) once for the app
Define Service
class UserRepo extends Effect.Service<UserRepo>()("UserRepo", {
sync: () => ({ find: (id: string) => Effect.succeed({ id }) })
}) {}