Loading search index…
No recent searches
No results for "Query here"
Composes functions with swapped middle arguments. Useful for complex function composition with argument reordering.
export const Goldfinch = (x: Fn) => (y: Fn) => (z: Fn) => (w: Fn) => x(w)(y(z)); export const G = Goldfinch;
const multiply = (x: number) => (y: number) => x * y; const addOne = (x: number) => x + 1; const complex = Goldfinch(multiply)(addOne); const result = complex(3)(10); // 40