juxt (juxtaposition)
Creates a function that calls multiple functions with the same arguments.
Takes several functions and returns a function that applies its arguments to
each of those functions. An array
of the results is returned.
Installation
yarn add juxt
or npm i juxt
Usage
juxt (fn<function>, fn<function>...)
- returns
{array}
const incr = val + 1const decr = val - 1 const juxtaposedCount = // [1, -1]