Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add nullable combinator #54

Open
garyb opened this issue Oct 17, 2022 · 0 comments
Open

Add nullable combinator #54

garyb opened this issue Oct 17, 2022 · 0 comments

Comments

@garyb
Copy link
Owner

garyb commented Oct 17, 2022

There is the maybe in Compat, but I'd rather have it more explicitly called out in the places I need it.

Also perhaps some kind of hybrid optional thing that disregards null as well as missing fields. The exact behaviour of that would need thinking about some, since when it comes to encoding Nothing there is a choice to be made - omit the field or specify null? It kinda suffers from the same ambiguity as nested Compat nulls. Maybe it's better just to have to deal with it manually, on a case by case basis by having to stack the optional and nullable and then use dimap to join / pure. 🤔

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant