-
Notifications
You must be signed in to change notification settings - Fork 22.4k
/
index.md
62 lines (42 loc) · 1.34 KB
/
index.md
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
---
title: "StorageAccessHandle: revokeObjectURL() property"
short-title: revokeObjectURL()
slug: Web/API/StorageAccessHandle/revokeObjectURL
page-type: web-api-instance-method
browser-compat: api.StorageAccessHandle.revokeObjectURL
---
{{APIRef("Storage Access API")}}
> **Note:** See {{domxref("URL.revokeObjectURL_static", "revokeObjectURL()")}} to understand usage.
## Syntax
```js-nolint
handle.revokeObjectURL(objectURL)
```
### Parameters
- `objectURL`
- : See {{domxref("URL.revokeObjectURL_static", "revokeObjectURL()")}}.
### Return value
None ({{jsxref("undefined")}}).
### Exceptions
- `SecurityError` {{domxref("DomException")}}
- : Thrown if access was not granted.
See {{domxref("URL.revokeObjectURL_static", "revokeObjectURL()")}}
## Examples
```js
document.requestStorageAccess({ revokeObjectURL: true }).then(
(handle) => {
console.log("revokeObjectURL access granted");
handle.revokeObjectURL(blob_url);
},
() => {
console.log("revokeObjectURL access denied");
},
);
```
> **Note:** See [Using the Storage Access API](/en-US/docs/Web/API/Storage_Access_API/Using) for a more complete example.
## Specifications
{{Specifications}}
## Browser compatibility
{{Compat}}
## See also
- {{domxref("Document.requestStorageAccess()")}}
- [Using the Storage Access API](/en-US/docs/Web/API/Storage_Access_API/Using)