Skip to content

@relu-interactives/spatial-ecs


@relu-interactives/spatial-ecs / index / collectDiffPaths

Function: collectDiffPaths() ​

ts
function collectDiffPaths(
   base, 
   current, 
   prefix?, 
   out?): string[];

Defined in: prefab/overrides.ts:338

Collect leaf paths where two canonical values differ. Semantics:

  • {$node} refs compare atomically by nodeId
  • arrays of differing length are ONE atomic override (the array path); equal lengths recurse per index
  • object key present on one side only marks that key's path
  • type mismatches mark the current path An empty-string path means the values differ at the top level.

Parameters ​

ParameterTypeDefault value
baseunknownundefined
currentunknownundefined
prefixstring""
outstring[][]

Returns ​

string[]