About multiple asynchronous requests in react components?

1, for example, I made two asynchronous requests in a component, and then found that this caused the component"s render,shouldComponentUpdate function to be executed many times, and console found that the state had not changed several times. How to solve this problem?
2. Another situation is that I found that my asynchronous request was executed twice each, but at the code level I only made one call request. What could be the cause of this?

Mar.02,2021

you judge whether the data has changed in should. If bean return false, will not render, request execution twice, there should be cross-domain. The first request is options

.
Menu