@adobe/data - v0.10.30
    Preparing search index...

    Type Alias IndexDeclarations<C, A>

    IndexDeclarations: {
        readonly [name: string]: {
            archetype?: StringKeyof<A>;
            components?: readonly StringKeyof<C>[];
            key: IndexKey<C>;
            order?: IndexOrder<C>;
            unique?: boolean;
        };
    }

    Plugin-level / store-level map of indexes. Keys are user-chosen index names; values are Index declarations whose key references real columns of C.

    The structural shape is inlined (rather than Index<C, any, any, any>) so that the per-entry key/order fields are actually constrained at the declaration site. With Index<C, any, any, any> the wildcard any generics widen key past IndexKey<C>, so a typo like { key: "bogus" } silently passes the constraint. Inlining key: IndexKey<C> here makes the typo a type error at the plugin descriptor.

    Type Parameters

    Type declaration

    • readonly [name: string]: {
          archetype?: StringKeyof<A>;
          components?: readonly StringKeyof<C>[];
          key: IndexKey<C>;
          order?: IndexOrder<C>;
          unique?: boolean;
      }

      Type declaration

      • Optional Readonlyarchetype?: StringKeyof<A>

        Scope the index to a single archetype (by declared name). Only entities that are that archetype (a superset of its components) are indexed — entities in other archetypes that merely share the key column are excluded. A is the schema's archetype map, so the name is checked against the declared archetypes; when unthreaded it widens to string.

      • Optional Readonlycomponents?: readonly StringKeyof<C>[]
      • Readonlykey: IndexKey<C>
      • Optional Readonlyorder?: IndexOrder<C>
      • Optional Readonlyunique?: boolean