@adviser/cement - v0.0.0
    Preparing search index...

    Interface KeyedNgItem<K, V, CTX>

    A structured item containing a key, value, and context.

    This is the fundamental container type used throughout the keyed-ng system. Items are created by KeyedNg and passed to factory functions and callbacks.

    const item: KeyedNgItem<string, number, MyContext> = {
    refKey: "user-123",
    givenKey: "user-123",
    value: 42,
    ctx: { config: 'production' }
    };
    interface KeyedNgItem<K, V, CTX> {
        refKey: string;
        givenKey: K;
        value: V;
        ctx: CTX;
    }

    Type Parameters

    • K

      The key type

    • V

      The value type

    • CTX

      The context type

    Index

    Properties

    refKey: string

    The normalized string key used for internal storage.

    This is the result of applying key2string to the givenKey.

    givenKey: K

    The original key as provided by the caller.

    This preserves the original key type and value, even if it's been converted to a string for storage.

    value: V

    The value associated with this key.

    Created by the factory function on first access.

    ctx: CTX

    The context provided when this item was created.

    Can be used to pass configuration or state to value factories.