rjhilgefort
4/17/2018 - 6:30 PM

mapP

console.clear()

const { log } = console
const add5P = compose(x => Promise.resolve(x), add(5))
const mapP = curry(
  (xf, data) => compose((x) => Promise.all(x), map(xf))(data)
);

mapP(add5P, [1, 5]).then(log)