React integration
External store subscribe
Registers a change listener and returns cleanup for that registration.
Formal Syntax & Structure
react syntaxreact
const unsubscribe = store.subscribe(listener)Working Example
Example Snippetreact
const unsubscribe = store.subscribe(listener)