fold
import { fold } from "https://github.gh-proxy.cn/raw.githubusercontent.com/baetheus/fun/main/record.ts";Collect all of the A values in a ReadonlyRecord into a single O value by the process of reduction. The order of key/value pairs in this reduction are stable and determined by ecmascript standard here.
@example
import * as R from "./record.ts";
import { pipe } from "./fn.ts";
const result = pipe(
{ one: 1, two: 2 },
R.fold((sum, value) => sum + value, 0),
); // 3