2 ms·
this is basically like bubbles under wallpaper - the "maybeness" is not due to your code, but due to the underlying problem you are solving (a user can either b
by zem 3y ago
this is basically like bubbles under wallpaper - the "maybeness" is not due to your code, but due to the underlying problem you are solving (a user can either be logged in or not, and if they are not then all user properties are null). the article identifies the problem with various solutions as extra layers of abstraction, but i feel like the real issue is ceremony - whether propagating maybe-coloured functions through your code and checking the return value everywhere, or wrapping everything in a monad, you have to do something to handle the null case when all you really care about is the non-null case, and that something inevitably feels like clutter and overhead.