Entity / foldkit-entity/transition
transitionOf
function · packages/entity/src/writeTransition.ts:145
function transitionOf(write: AnyWrite): WriteTransitionThe transition of write. It applies where the row is present (an
insert: is not), the write's when and from hold, and the revision it
expects is the row's. Its writes are in the module's own description; the
revision's new value is the store's to choose, so it is an opaque value that
reads the old one and gives one more, as the reference stores do.
An input key that may be left out sets "the key if given, else the field as
it was". Evaluation reads a key left out as null, so where the field cannot
hold null that is a choice on the key being null; where it can, the value is
opaque, reading both, and a rule over that field is unknown to the checker.
The id is not written: it names the row, as Write.footprint has it.