Last active
May 1, 2018 14:33
-
-
Save kylecorbelli/be7967767c19c8af052d7b97797c7b32 to your computer and use it in GitHub Desktop.
Revisions
-
kylecorbelli revised this gist
May 1, 2018 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or 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 charactersOriginal file line number Diff line number Diff line change @@ -5,4 +5,4 @@ const upperCaseHead: UpperCaseHead = compose( ) as UpperCaseHead console.log(upperCaseHead([])) // { type: Maybe.Nothing } ie. Nothing console.log(upperCaseHead([ 'rick', 'morty' ])) // { type: Maybe.Just, value: 'RICK' } ie. Just 'RICK' -
kylecorbelli revised this gist
Apr 30, 2018 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or 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 charactersOriginal file line number Diff line number Diff line change @@ -5,4 +5,4 @@ const upperCaseHead: UpperCaseHead = compose( ) as UpperCaseHead console.log(upperCaseHead([])) // { type: Maybe.Nothing } ie. Nothing console.log(upperCaseHead([ 'rick', 'morty' ])) // { type: Maybe.Just, value: 'rick' } ie. Just 'Rick' -
kylecorbelli revised this gist
Apr 30, 2018 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or 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 charactersOriginal file line number Diff line number Diff line change @@ -5,4 +5,4 @@ const upperCaseHead: UpperCaseHead = compose( ) as UpperCaseHead console.log(upperCaseHead([])) // { type: Maybe.Nothing } ie. Nothing console.log(upperCaseHead([ 'rick', 'morty' ])) // { type: Maybe.Just, value: 'rick' } ie. Just 'Rick'> -
kylecorbelli created this gist
Apr 30, 2018 .There are no files selected for viewing
This file contains hidden or 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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,8 @@ type UpperCaseHead = (list: ReadonlyArray<string>) => Maybe<string> const upperCaseHead: UpperCaseHead = compose( Maybe.map(toUpper), safeHead, ) as UpperCaseHead console.log(upperCaseHead([])) // { type: Maybe.Nothing } ie. Nothing console.log(upperCaseHead([ 'rick', 'morty' ])) // { type: Maybe.Just, value: 'rick' } ie. Just<string>