How can i excute a function after all ajax requests complete?

2.8k views Asked by At

I wanna execute a JS Function after all Ajax request in the page complete. But in the general way. Because i don't know how many Ajax Requests in the page. and i wanna make the code declarative to run even it the developer create an Ajax request in future.

let's take this code Example:

function ex(){
 alert("all Ajax requests have been sent");
}
0

There are 0 answers