DeclaredInvariant.id
property · packages/entity/src/invariant.ts:121
readonly id: stringEntity / foldkit-entity
interface · packages/entity/src/invariant.ts:119
interface DeclaredInvariant<E extends AnyEntity> {
(entity: E): E
readonly id: string
readonly entity: string
}An invariant as declared: the step that attaches it to its Entity, carrying
its id and, once attached, that Entity's name, so a refusal is matched
against the declaration rather than a string spelled again
(Refusal.isInvalidBy(refusal, reservedWithinQuantity)). An id is unique
only within an Entity, so the name is part of what a refusal names; reading
it before the declaration is attached throws.
DeclaredInvariant.idproperty · packages/entity/src/invariant.ts:121
readonly id: stringDeclaredInvariant.entityproperty · packages/entity/src/invariant.ts:122
readonly entity: string