Removes from update any values that are identical in a LAYERED original.
The layers are ordered nearest-first: for each leaf the first layer that defines it (undefined
is 'not defined', null is a value) is the one it is compared against. This is
removeEqualValues against the deep merge of the layers, without materializing that merge —
which matters when the layers hold resolved model objects rather than plain json.
Parameters
update: any
The object to update.
layers: readonlyany[]
The original values to compare against, nearest layer first. Nullish layers are ignored.
Removes from update any values that are identical in a LAYERED original.
The layers are ordered nearest-first: for each leaf the first layer that defines it (
undefinedis 'not defined',nullis a value) is the one it is compared against. This is removeEqualValues against the deep merge of the layers, without materializing that merge — which matters when the layers hold resolved model objects rather than plain json.