CreateReactiveStoreWithInitialValueAndSlotTrackingConfig

type CreateReactiveStoreWithInitialValueAndSlotTrackingConfig<TInitialValue, TStreamValue, TItem> = Readonly<{
  initialValueMapper: (value) => TItem;
  initialValueSource: ReactiveActionSource<SolanaRpcResponse<TInitialValue>>;
  streamSource: ReactiveStreamSource<SolanaRpcResponse<TStreamValue>>;
  streamValueMapper: (value) => TItem;
}>;

Configuration for createReactiveStoreWithInitialValueAndSlotTracking. Pairs a one-shot initial-value source with an ongoing stream source so the resulting store can hydrate from the initial response and keep up to date with notifications, slot-deduplicating the two sources.

Type Parameters

Type ParameterDescription
TInitialValueThe value type produced by initialValueSource (inside the SolanaRpcResponse envelope).
TStreamValueThe value type emitted by streamSource (inside the SolanaRpcResponse envelope).
TItemThe unified item type the store holds, produced by the two value mappers.

See

createReactiveStoreWithInitialValueAndSlotTracking

On this page