Closed TrySound closed 6 years ago
Nice work on the perf! As mentioned in #89 I think I'd prefer if these remained being called derive
and mDerive
, since map
is normally used for transforming collections or streams, but that's only a soft preference. If you prefer map
and mMap
a lot more, then I'm happy for you to make that change too.
Derivable with derive method is functor in terms of fp, so it won't confuse and conflict with different types (types + namespace). Also derive method will conflict with lightweight derive function, since they'll have different functionality.
Ok, go for it! :+1:
Proposed in https://github.com/ds300/derivablejs/pull/89
map
andmMap
methods. Not overloaded versions are 25% faster as you can find in added benchmarks/cc @ds300 @andreypopp