loading...

re: A simple explanation of functional pipe in JavaScript VIEW POST

FULL DISCUSSION
 

Unfortunately typescript doesn't provide a good way to impose type constraints on functions with unlimited variadic arguments.

So pipeline function implementations like the above can be made type safe only by repeated overrides upto an arbitrarily determined maximum arity. Example.

I am curious why the RxJS team didn't opt for a fluent API (like this one) which does not suffer from a similar issue.

 

They originally did use a fluent API. Then for RxJS5... bad decisions were made.

Code of Conduct Report abuse