TanStack

SubscribePropsWithSource

Type Alias: SubscribePropsWithSource<TSourceValue, TSelected>

ts
type SubscribePropsWithSource<TSourceValue, TSelected> =
  | SubscribePropsWithSourceIdentity<TSourceValue>
| SubscribePropsWithSourceWithSelector<TSourceValue, TSelected>;

Defined in: types.ts:156

Subscribe to a single source — atom or store (identity or projected). Prefer SubscribePropsWithSourceIdentity or SubscribePropsWithSourceWithSelector for clearer inference when selector is omitted.

Type Parameters

TSourceValue

TSourceValue

TSelected

TSelected = TSourceValue