The >>
and <<
functions in Elm allow you to combine two functions to produce a new function. The resulting function is most often useful when passed as a parameter to functions like map
and filter.
. The direction of the arrow implies how the result is passed along between the functions.
Examples
Http.post url Http.emptyBody decoder
|> Http.toTask
|> Task.map (.status >> String.toUpper)
|> Task.mapError (RemotelyStoreError << httpErrorToString)
Links