function mapValues()

in packages/sdk/src/Schema.ts [142:148]


function mapValues<T, U>(record: Record<string, T>, callb: (value: T, key: string) => U): Record<string, U> {
  const mapped: Record<string, U> = {};
  for (const key of Object.keys(record)) {
    mapped[key] = callb(record[key], key);
  }
  return mapped;
}