import { unary } from "https://deno.land/x/fun@v2.0.0/fn.ts";
Take a variadic Fn and make it unary, collapsing multiple arguments into a single tuple argument.
Examples
Example 1
Example 1
import * as F from "./fn.ts";
const person = (age: number, name: string) => ({ age, name });
const personUnary = F.unary(person);
// ({ name: "Brandon", age: 37 })
const result1 = personUnary([37, "Brandon"]);