Created
December 23, 2018 06:27
-
-
Save rjhilgefort/e64ede5223f29624d3dc2a4bc8a4a915 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const maybeHof = compose(when, complement)(isNil) | |
const maybeToUpper = maybeHof(toUpper) | |
maybeToUpper(null) // null | |
maybeToUpper(undefined) // undefined | |
maybeToUpper('foo') // 'FOO' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment