is my code:
const result = await Promise.all(
files.map(async (url: string) => {
console.log('Fetching', url);
const res = await fetch(url);
return res.json();
})
);
console.log(result);
And it throws an error: Uncaught (in promise) TypeError: Failed to fetch
The urls are all https://google.com just for testing purposes. Any recommendations, please?
From node or browser?
Обсуждают сегодня