Experimental
The unique store identifier.
A function that returns a snapshot of the data in the store that’s
needed by the component. While the store has not changed,
repeated calls to getSnapshot
must return the same value.
If the store changes and the returned value is different
(as compared by Object.is
), React re-renders the component.
A function that takes a single callback argument onStoreChange
and
subscribes it to the store. When the store changes, it should invoke
the provided callback. This will cause the component to re-render.
The subscribe function should return a function that cleans up the
subscription.
Generated using TypeDoc
A store that has a state of type
State
. A store informs clients about state changes and publishes its state as a stable snapshot.