skip to Main Content

Javascript – Promise all is blocking other fetch call

I actually consume some remote API using the FETCH API like below document.addEventListener("DOMContentLoaded", () => { loadCart(); aggregateSearch("france", ["api1", "api2"]); }); const aggregateSearch = async (term, AvailableApis) => { console.log("aggregateSearch") await Promise.all(AvailableApis.map((api) => { fetchApi(api, term); })) }; const fetchApi…

VIEW QUESTION
Back To Top
Search