useTransitionValue()function

useTransitionValue(store: S): S["value"]
ParamType
storeS
The store to read. Its value must not be loading or failed. required
Return
S["value"]
The store's current value.

Read a store's value, and re-render inside startTransition() when it changes, so <ViewTransition> boundaries animate.

  • useStore() uses useSyncExternalStore(), and React always applies those updates synchronously. A synchronous update never starts a view transition.
  • This hook copies the value into React state inside startTransition() instead.
  • Internal for now: not exported from the shelving/ui barrel.