Effect CommunityEC
Effect Community2y ago
10 replies
adrian_g

Adding custom error message to Effect.fromNullable

Would it make sense to add options argument to Effect.fromNullable which would allow to set custom error message? So we could do:

Effect.fromNullable(nullable, { message: () => 'my message' })


or in pipeline:

pipe(
  nullable,
  Effect.fromNullable({ message: () => 'my message' }),
)


Happy to open a PR
Was this page helpful?