parallel-js/parallel.js

Is it possible to use such function: (data: N) => T as the parameter of the map method?

Opened this issue · 0 comments

I'm using Typescript. The current map only accepts functions like : fn: (data: N) => N. But in practice, I need to feed the map with function like : (data: N) => T. T is not the same type as N. Could you tell me how to do it?
Thank you so much!

public map<N>(fn: (data: N) => N): Parallel<T>