Selects which persistent quadrants a toData / fromData operates on. Both
quadrants are persistent; they differ only by sharing:
shared → the shared + persistent quadrant ("document")
nonShared → the nonShared + persistent quadrant ("settings")
Omit the scope entirely to operate on the whole persistent snapshot (both
quadrants) — the default, whole-database behavior. Passing a scope makes the
operation surgical: toData emits row data only for the in-scope quadrant(s)
(every archetype's structure is still emitted so archetype ids stay aligned),
and fromData restores only the in-scope quadrant(s), leaving every other
quadrant — persistent or not — untouched. This lets one service own
settings while another owns document, each persisting to its own backend.
Selects which persistent quadrants a
toData/fromDataoperates on. Both quadrants are persistent; they differ only by sharing:shared→ the shared + persistent quadrant ("document")nonShared→ the nonShared + persistent quadrant ("settings")Omit the scope entirely to operate on the whole persistent snapshot (both quadrants) — the default, whole-database behavior. Passing a scope makes the operation surgical:
toDataemits row data only for the in-scope quadrant(s) (every archetype's structure is still emitted so archetype ids stay aligned), andfromDatarestores only the in-scope quadrant(s), leaving every other quadrant — persistent or not — untouched. This lets one service ownsettingswhile another ownsdocument, each persisting to its own backend.