Requesting Storage Persistance
Open app.js
and insert the following code:
(async function() {
if (navigator.storage && navigator.storage.persist) {
if (! await navigator.storage.persisted()) {
const result = await navigator.storage.persist();
console.log(`Was Persistent Storage Request granted? ${result}`);
} else {
console.log(`Persistent Storage already granted`)
}
}
}
)();