Avoiding 'NoSuchElementException' in a TypeScript code snippet
Hi
how to avoid 'NoSuchElementException' here ?
how to avoid 'NoSuchElementException' here ?
pipe(
Effect.succeed([]),
Effect.flatMap(arr => arr.length > 0 ? Option.some('value') : Option.none()),
)