Implementing `Effect.Service` with Parameterized Configuration

Is it possible with Effect.Service to have an implementation that requires some parameters?

I was using this to provide Config
export class Paddle extends Context.Tag("Paddle")<
  Paddle,
  Effect.Effect.Success<ReturnType<typeof make>>
>() {
  static readonly Live = (config: Config.Config.Wrap<PaddleConfig>) =>
    Config.unwrap(config).pipe(Effect.flatMap(make), Layer.effect(this));
}
Was this page helpful?