Promise.all(files.map(file => {
const storageRef = ref(storage, `${name}/${file.name}`);
return uploadBytes(storageRef, file).then(() => {
return getDownloadURL(storageRef).then((url)=>{
return url;
})
})
})).then((values)=>{
console.log(values)
})