Skip to content

Commit

Permalink
Add storage idl file
Browse files Browse the repository at this point in the history
  • Loading branch information
Luke Bjerring committed Mar 7, 2018
1 parent fbf57c4 commit 5bbb4c1
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions interfaces/storage.idl
@@ -0,0 +1,20 @@
[SecureContext]
interface mixin NavigatorStorage {
readonly attribute StorageManager storage;
};
Navigator includes NavigatorStorage;
WorkerNavigator includes NavigatorStorage;

[SecureContext,
Exposed=(Window,Worker)]
interface StorageManager {
Promise<boolean> persisted();
[Exposed=Window] Promise<boolean> persist();

Promise<StorageEstimate> estimate();
};

dictionary StorageEstimate {
unsigned long long usage;
unsigned long long quota;
};

0 comments on commit 5bbb4c1

Please sign in to comment.