trusat-frontend icon indicating copy to clipboard operation
trusat-frontend copied to clipboard

Moving between pages before API call has finished may cause memory leaks

Open johngribbin opened this issue 4 years ago • 1 comments

See error in console when you navigate away from the "catalog" view before the data is returned from the API:

Warning: Can't perform a React state update 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 a useEffect cleanup function.
    in CatalogTable (at Catalog.js:46)
    in div (at Catalog.js:17)
    in Catalog (created by Context.Consumer)
    in withRouter(Catalog) (created by Context.Consumer)

johngribbin avatar Dec 11 '19 05:12 johngribbin