danielnarey/elm-toolkit/6.0.0

NOTE: this package is not compatible with Elm 0.19.1

Toolkit.Function.Operators

(||>) : a -> (a -> b) -> b

Forward function application with precedence set to 9. Allows you to avoid parentheses when you want the argument to appear before the function name in an inline expression.

1 ||> toString ++ 2 ||> toString    --> "12"
(@@|>) : ( a, b ) -> (a -> b -> c) -> c

Forward operator for uncurry with 2 parameters

(1,2) @@|> (+)    --> 3
(#) : (a -> b -> c) -> b -> a -> c

An operator for flip. Think of the # symbol as appearing where the missing argument would go.

4 |> (/) 2        --> 0.5
4 |> flip (/) 2   --> 2
4 |> (/) # 2      --> 2