Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/earthstar/src/sync-fs/util.ts>getTupleWinners

Earthstar is a tool for private, undiscoverable, offline-first networks.
Go to Latest
function getTupleWinners
import { getTupleWinners } from "https://deno.land/x/earthstar@v10.0.0-alpha.3/src/sync-fs/util.ts";

Type Parameters

TypeA
TypeB

Parameters

zippedRecord: Record<string, [TypeA | null, TypeB | null]>
determineWinner: (a: TypeA | null, b: TypeB | null) => TypeA | TypeB

Returns

Record<string, (TypeA | TypeB)>