Skip to content

ConflictStrategy

ConflictStrategy: "manual" | "local-wins" | "remote-wins" | "last-write-wins"

Defined in: packages/store-kit/src/types.ts:102

Strategy applied when a remote update collides with a pending local delta whose baseline has diverged from the new remote value.

  • manual — record a Conflict for the path; local value remains in place until the user explicitly resolves it via Store.resolveConflict(path, choice).
  • local-wins — silently keep the local delta; drop the remote update for this path.
  • remote-wins — discard the local delta and apply the remote value.
  • last-write-wins — compare the delta timestamp with the remote observation timestamp; newer wins.