When calling setDiffDeep, if the before and after values are non-object & non-array, a model._set will always be invoked -- even if the two values are equal.
This is especially noticeable in model.start which has a default behavior of applying updates to the output path with mode = 'diffDeep' and can cause a VERY large number of updates to be propagated in a complex app even where there was no actual change to the data.
When calling
setDiffDeep
, if thebefore
andafter
values are non-object & non-array, amodel._set
will always be invoked -- even if the two values are equal.See: https://github.com/derbyjs/racer/blob/3d9cb6ea6d5a8326e7ad51d7bc34542ec20f0e1d/lib/Model/setDiff.js#L59-L65
This is especially noticeable in
model.start
which has a default behavior of applying updates to the output path withmode = 'diffDeep'
and can cause a VERY large number of updates to be propagated in a complex app even where there was no actual change to the data.