elm-community/basics-extra/1.0.1

NOTE: this package is not compatible with Elm 0.19.1

Basics.Extra

Additional basic functions

never : Never -> a

The empty function. This converts a value of type Never into a value of any type, which is safe because there are no values of type Never. Useful in certain situations as argument to Task.perform and Html.App.map.

Note: To use this function, its argument need not be literally of type Never. It suffices if it is a fully polymorphic value. For example, this works: Process.sleep >> Task.perform never (\() -> ...), because the output of Process.sleep is fully polymorphic in the x of Task x ().