Subscribe to a live source and return the current value of a reducer
mapping, updated on a throttle. Equivalent to
useSnapshot(src).tail(tail).reduce(mapping) but with one subscription,
one memo, and narrow per-entry types inherited from
TimeSeries.reduce.
Returns a stable-shape object while the source has no events (every
mapped field is undefined), so destructuring on first render is
safe.
Reference stability: when a new event push leaves the reduce
output structurally unchanged (same scalar values, same-length arrays
with same elements), the previous result reference is returned
unchanged. Downstream useMemo([value]) and useEffect([value]) only
re-run when the value actually changes — no need for a manual
.slice() or deep-compare equality helper at the call site.
Subscribe to a live source and return the current value of a reducer mapping, updated on a throttle. Equivalent to
useSnapshot(src).tail(tail).reduce(mapping)but with one subscription, one memo, and narrow per-entry types inherited fromTimeSeries.reduce.Returns a stable-shape object while the source has no events (every mapped field is
undefined), so destructuring on first render is safe.Reference stability: when a new event push leaves the reduce output structurally unchanged (same scalar values, same-length arrays with same elements), the previous result reference is returned unchanged. Downstream
useMemo([value])anduseEffect([value])only re-run when the value actually changes — no need for a manual.slice()or deep-compare equality helper at the call site.