I need 2 ajax request are complet before run the callback function RUN_ACTIONS() of the first request, but how waiting it ( whit optimize the temp waiting )?
function ajax() {
d3.tsv( ajaxUrl,
function(data) {
while (!secondAJAXQueryComplet());
RUN_ACTIONS(HEADER, data);
}
);
d3.json( ajaxUrl,
function(header) {
define_Header(header);
}
);
}