Inferring when using tuple as inputs

Viewed 42

Is there a way to infer the following? i.e. Where the parameter of the function is inferred from position 0 of the tuple for each entry of the array?

fn([
 [ objA, (val)=>{} ],
          ^^^ Inferred to same type as `objA`
 [ objB, (val)=>{} ],
          ^^^ Inferred to same type as `objB`
])
0 Answers
Related