data-cap
    Preparing search index...

    Interface DiscoveredCapability

    One buildData/createData capability, linked with its correlated documentData() call (if any).

    interface DiscoveredCapability {
        declarationPosition: SourcePosition;
        docs: LooseCapabilityDocs | undefined;
        documentedBy: { file: string } | undefined;
        exportName: string;
        fieldPositions: Readonly<Record<string, SourcePosition>> | undefined;
        fieldsShape: Record<string, unknown> | undefined;
        file: string;
        kind: "buildData" | "createData";
        operationNames: OperationNames | undefined;
        operationPresence: OperationPresenceByKind | undefined;
        operationWrites: OperationWritesByKind | undefined;
    }
    Index
    declarationPosition: SourcePosition

    Position of this capability's own buildData/createData call site -- always available.

    docs: LooseCapabilityDocs | undefined

    Statically-extracted governance metadata from the correlated documentData() call, if any -- undefined when documentedBy is undefined, or when its docs argument wasn't an inline object literal.

    documentedBy: { file: string } | undefined

    The documentData() call correlated with this capability, if any.

    Type Declaration

    • { file: string }
      • Readonlyfile: string

        Absolute path of the file declaring the correlated documentData() call.

    • undefined
    exportName: string

    The binding name the capability is exported as.

    fieldPositions: Readonly<Record<string, SourcePosition>> | undefined

    Position of each top-level field's own key, keyed by field name -- only when fields was an inline object literal in this file (see parse.ts's extractFieldPositions); undefined when identifier-resolved across a file boundary.

    fieldsShape: Record<string, unknown> | undefined

    The literal-evaluated fields shape, or undefined when it couldn't be statically resolved (see accompanying warnings).

    file: string

    Absolute path of the file declaring this capability.

    kind: "buildData" | "createData"

    "buildData" or "createData" -- which call form declared this capability.

    operationNames: OperationNames | undefined

    Static getter/mutator/subscription names (never their function bodies) -- only ever populated for a createData() call; undefined for buildData(), which has no operations section.

    operationPresence: OperationPresenceByKind | undefined

    Static processor/optimistic key-presence facts, keyed the same way as operationNames -- undefined under the same condition.

    operationWrites: OperationWritesByKind | undefined

    Static writes field-ownership shapes, keyed the same way as operationNames -- undefined under the same condition.