Elixir Streams |> 🤩 Better defaults with Enum.find/3
🔥 little trick that makes Enum.find
better.
Use Enum.find/3
and set a default option. It can be a good default or a nicer error message!
🎥 Elixir Streams |> 🤩 Better defaults with Enum.find/3
Read next Creating Custom Exceptions in Elixir