Just wanted to clarify pipe vs compose jargon for your readers. In your article you referred to the use of .reduce() as a way to "compose" functions. Actually, that is a "pipe" whereas .reduceRight() provides a "compose". Pipe works left to right through the function array and compose right to left. Compose is a mathematical term for evaluation order like f(g(x)). Thank you though for your examples.
Just wanted to clarify pipe vs compose jargon for your readers. In your article you referred to the use of .reduce() as a way to "compose" functions. Actually, that is a "pipe" whereas .reduceRight() provides a "compose". Pipe works left to right through the function array and compose right to left. Compose is a mathematical term for evaluation order like f(g(x)).
Thank you though for your examples.