The fetch request in javascript:
async () => {
try {
const urls = [
"http://localhost:3001/foo",
"http://localhost:3001/foo",
"http://localhost:3001/foo",
"http://localhost:3001/foo",
];
const requests = urls.map((url) => fetch(url));
const responses = await Promise.all(requests);
const errors = responses.filter((response) => !response.ok);
}
}
I want the request to fire in parallel. But in dev tools in chrome this is shown:
Now when i disable the cache in devtools, it does work in parallel:
Confused on how to make it work without disabling the cache in devtools.
Thanks