udash-core icon indicating copy to clipboard operation
udash-core copied to clipboard

Attempt merging patches in callback sequencer

Open ddworak opened this issue 4 years ago • 0 comments

TBH I'm not a fan of both solutions right now. In a test case you've pointed out I'd expect single patch emitted with:

  • 5 elements removed: (1, 2), (3, 4), (7, 8), (9, 10), (13, 14),
  • 4 elements added: (3, 4), (7, 8), (9, 10), (13, 14).

If we can't implement a structure listener this way, I'd prefer previous behaviour (emitting an "intermediate" patch with defaultA value used, and then a "final" one) than current (emitting the "final" patch, and removing/adding the same afterwards). However we should fire a structure listener once IMO if both elements are removed from numbers within a CallbackSequencer.

Originally posted by @bgrochal in https://github.com/UdashFramework/udash-core/pull/735#discussion_r696765449

ddworak avatar Aug 27 '21 08:08 ddworak