Effect CommunityEC
Effect Community3y ago
81 replies
Emberoshi

Recovering from a Failure in Effect.gen

Hey guys, how can I recover a failure of an Effect.gen? Example
const program = Effect.gen(function* (_) {
    ...
}).pipe(Effect.catchTag("SomeError", () => {
  // do something and restart the program
}))
Was this page helpful?