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

Memory Leak? #20

Open
mikecann opened this issue Nov 11, 2018 · 0 comments
Open

Memory Leak? #20

mikecann opened this issue Nov 11, 2018 · 0 comments

Comments

@mikecann
Copy link

mikecann commented Nov 11, 2018

Hey,

Im very new to Reason so was just looking through this codebase trying to learn real-world examples of how to do things and I came across this line:

https://github.com/reasonml-community/reason-react-hacker-news/blob/master/src/TopStoriesPage.re#L49

Im wondering if this is a memory leak because it doesnt get un-listened when the component unmounts?

It might explain this console error you get when running locally:

main.js:3176 Warning: Can't call setState (or forceUpdate) on an unmounted component. This is a no-op, but it indicates a memory leak in your application. To fix, cancel all subscriptions and asynchronous tasks in the componentWillUnmount method.
in TopStoriesPage (created by App)

Im submitting this is an issue rather than doing a PR because im very new so no doubt im missing something here. Ill happily attempt a PR if this is indeed an issue.

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

No branches or pull requests

1 participant