Every story and comment from the Hacker News API, in a layout borrowed from 2001.
A comment on Why is setState asynchronous?. Parent comment
However, instead of calling forceUpdate(), I was under the impression that componentWillReceiveProps(props) was more efficient?
Perhaps I'm wrong on that one, though... Just that forceUpdate() is an approach that is officially encouraged against.[0]
[0] - https://reactjs.org/docs/react-component.html#forceupdate
There are no comments on this comment yet.
However, instead of calling forceUpdate(), I was under the impression that componentWillReceiveProps(props) was more efficient?
Perhaps I'm wrong on that one, though... Just that forceUpdate() is an approach that is officially encouraged against.[0]
[0] - https://reactjs.org/docs/react-component.html#forceupdate