Skip to content

Commit

Permalink
Update files/en-us/web/api/storage_access_api/using/index.md
Browse files Browse the repository at this point in the history
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
  • Loading branch information
arichiv and github-actions[bot] committed May 3, 2024
1 parent 47a01a7 commit 5e3fa9b
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion files/en-us/web/api/storage_access_api/using/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,10 @@ async function handleCookieAccess() {
if (permission.state === "granted") {
// If so, you can just call requestStorageAccess() without a user interaction,
// and it will resolve automatically.
const handle = await document.requestStorageAccess({cookies: true, localStorage: true});
const handle = await document.requestStorageAccess({
cookies: true,
localStorage: true,
});
doThingsWithLocalStorage(handle);
doThingsWithCookies();
} else if (permission.state === "prompt") {
Expand Down

0 comments on commit 5e3fa9b

Please sign in to comment.