|
ap<B, C>(fs: Stream<(a: A) => B>): Stream<C>; |
Not sure how this can have survived for so long, but this type suggests that you should pass a stream of functions to f$.ap() when in fact you should pass a stream of values.
The typings below should be the correct ones.
ap<
B = A extends (x: infer B) => any ? B : never,
C = A extends (x: any) => infer C ? C : never
>(
x$: Stream<B>
): Stream<C>;
This also works
ap(
x$: Stream<A extends (x: infer B) => any ? B : never>
): Stream<A extends (x: any) => infer C ? C : never>;
Should I make a PR?
most/type-definitions/most.d.ts
Line 75 in bfed148
Not sure how this can have survived for so long, but this type suggests that you should pass a stream of functions to
f$.ap()when in fact you should pass a stream of values.The typings below should be the correct ones.
This also works
Should I make a PR?