Closed haf closed 9 years ago
Yeah, that seems useful - something like a function Json.readOrDefault
if that's possible? It would make sense to have that I agree. How does 'readOrDefault' sound to you, and would that be the right thing?
Yes, that sounds about right!
I'll have a look at it later on then and try and push it as a 4.1 :)
Nice
A default function for 'this property might not exist, because it was introduced later:
By default I think it's a good idea to be backwards-compatible with schema, so if the library's user knows that a property has been introduced later, then there should be an easy way (i.e. one that doesn't require reasoning about the monad's structure) to read that properly optionally, like above.