docs(session-projection): stop describing a removed interlock

This commit is contained in:
imccyu committed 2026-10-19 03:00:08 +08:00
1 parent 8ff30ebd96
commit af2fa50f8a
2 files changed
+6 -4

No files matched your search

@@ -186,7 +186,7 @@ interface ErasedDefinition {
wire: {
viewSchema: { parse(value: unknown): unknown }
view(state: unknown): unknown
/** Whether a Session summary carries this unit (false only for a marked key). */
/** Whether a Session summary carries this unit (false when the unit declared `summary: false`). */
summary: boolean
} | undefined
stateVersion: number
@@ -313,7 +313,7 @@ export class SessionProjectionRegistry extends Service {
apply: (state, event) => definition.apply(state as S, event),
// The summary mark has no runtime representation: `wire.view` and
// `viewSchema` are already typed with the mark stripped, so this erase
// only widens the state type. `summary` carries the interlock outcome
// only widens the state type. `summary` carries the declared membership
// into the erased unit, where the key set reads it.
wire: wire === undefined
? undefined
@@ -13,8 +13,10 @@
* leaves out. The symbol never exists at runtime: a marked entry keeps its
* plain JSON value, `SessionProjectionViewValue` strips the mark in the wire
* and client view types, and the only runtime fact is the `summary: false`
* declared at registration. A marked key must declare it, and summary reads
* skip exactly those keys.
* declared at registration. A marked key's registration declares
* `summary: false` so the runtime key set and the client view type agree, and
* `summaryKeys()` skips exactly those keys; the registration types do not
* enforce that pairing.
*/
declare const sessionProjectionSummaryExcluded: unique symbol