https://github.com/the-road-to-learn-react/react-asynchronous-request-setstate-unmounted-component
Example of preventing to set state on unmounted React Components
https://github.com/the-road-to-learn-react/react-asynchronous-request-setstate-unmounted-component
asynchronous react reactjs setstate
Last synced: 2 months ago
JSON representation
Example of preventing to set state on unmounted React Components
- Host: GitHub
- URL: https://github.com/the-road-to-learn-react/react-asynchronous-request-setstate-unmounted-component
- Owner: the-road-to-learn-react
- Created: 2018-10-08T03:52:57.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2020-12-28T22:37:06.000Z (over 4 years ago)
- Last Synced: 2025-03-24T07:07:05.560Z (3 months ago)
- Topics: asynchronous, react, reactjs, setstate
- Language: JavaScript
- Homepage: http://roadtoreact.com
- Size: 1.57 MB
- Stars: 13
- Watchers: 3
- Forks: 7
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# react-asynchronous-request-setstate-unmounted-component
[](https://travis-ci.org/the-road-to-learn-react/react-asynchronous-request-setstate-unmounted-component) [](https://slack-the-road-to-learn-react.wieruch.com/) [](https://greenkeeper.io/)
Showcasing how to prevent to set state on unmounted React components when having an asynchronous request in place. [Read more about it](https://www.robinwieruch.de/react-warning-cant-call-setstate-on-an-unmounted-component).
## Installation
* `git clone [email protected]:the-road-to-learn-react/react-asynchronous-request-setstate-unmounted-component.git`
* cd react-asynchronous-request-setstate-unmounted-component
* npm install
* npm start
* visit `http://localhost:3000`