const handleSelectedItem = (id) => {
console.log('one click')
updateData(id)
};
const fetch1 = () => fetch(url1).then(r => r.json());
const fetch2 = () => fetch(url2).then(r => r.json());
const arr = [fetch1, fetch2];
const arr = [
() => new Promise(
r => setTimeout(() => r("Petrov"), 1000)
),
() => new Promise(
r => setTimeout(() => r("Petr"), 1000)
),
() => new Promise(
r => setTimeout(() => r("Petrovich"), 1000)
)
];
giveMeName().then(r => console.log(r.join(" "))) // Petrov Petr Petrovich
const arr = [() => Promise.resolve(5), () => 6, () => 24]
const arr = [() => Promise.resolve(5), () => 6, () => 24]
giveMeName() // [5, 6, 24]