DEV Community

Discussion on: Cache Busting a React App

Collapse
 
amanchaudhary1998 profile image
AmanChaudhary1998

While Implementing these code I am stuck into the infinite loop
can anyone help me to where I am commit the mistake
if (caches) {
const names = await caches.keys();
console.log(names);
await Promise.all(names.map((name)=>caches.delete(name)))
}
window.location.reload();