In-game tools · function
divergentComponents
Which components two sides hash differently, into out. Returns how many.
Explained in In-game tools.
function divergentComponents(ours: ReadonlyMap<string, string>, theirs: ReadonlyMap<string, string>, out: string[]): numberimport { divergentComponents } from '@driftengine/tools';Parameters
| Parameter | Type | Description |
|---|---|---|
ours | ReadonlyMap<string, string> | |
theirs | ReadonlyMap<string, string> | |
out | string[] |
In depth
A component only one side has is a divergence too, and the loudest kind: it means one peer created or destroyed something the other did not.