Skip to content

Instantly share code, notes, and snippets.

@awto
Created March 8, 2019 15:08
Show Gist options
  • Save awto/52528eee8318d05205c7767ccda0fc92 to your computer and use it in GitHub Desktop.
Save awto/52528eee8318d05205c7767ccda0fc92 to your computer and use it in GitHub Desktop.
join from chain and of
const join = (of, chain) => args => args.reduceRight(
(acc, eff) => result => chain(eff, element => acc([...result, element])), of)([]);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment