I'm facing a challenge with what should be simple. The types aren't coming through as expected when trying to combine a couple of functions. Is there a way to have TypeScript infer the types without explicitly specifying them?
import { pipe, map } from 'ramda'
type TODO = unkown
export const mapP = (xf: TODO) => (data: TODO) =>
pipe(
map(xf),
x => Promise.all(x),
)(data)
I just want map
to determine the types for the function and not have to manually input them again. Thank you in advance!