Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Anyway to remove an instance from instances list? #376

Open
unidevel opened this issue Jun 23, 2017 · 1 comment
Open

Anyway to remove an instance from instances list? #376

unidevel opened this issue Jun 23, 2017 · 1 comment

Comments

@unidevel
Copy link

unidevel commented Jun 23, 2017

Hi,
I have some widgets associate store by itself, however when widget is unmount, seems its store is still under the list make it looks like a memory leak issue. Is there any way I can add some code to componentWillUnmount to remove the store from the list?
Maybe by dispatching an action with special type like INIT action in redux?

@zalmoxisus
Copy link
Owner

Currently it's not possible for Redux enhancer. If you're using the extension only for logging, you can reimplement it using the API. So, can call unsubscribe() on componentWillUnmount. Here's an example of the implementation as a store enhancer.

But we should have it out of the box for the enhancer, just not sure how the API should look like.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants