I have many requests, and they will all be sent out at once, and then all of them will be in a waiting state, causing the code to be asynchronous. How can I change the axios request to be synchronous, that is, after one request is completed, the next request is sent?
What I need is that after all these requests are completed, a list will be returned to me, which contains all the results
Note: The number of requests is uncertain, and the parameters are also uncertain. Now it is requested by a for loop.
Using axios.all can trigger the callback only when multiple ajax requests are completed. Reference: https://www.npmjs.com/package...
axios does not support synchronous requests at all