#import #import // https://w3c.github.io/ServiceWorker/#cachestorage-interface [SecureContext, Exposed=(Window,Worker)] interface CacheStorage { [NewObject] Promise<(Response or undefined)> match(RequestInfo request, optional MultiCacheQueryOptions options = {}); [NewObject] Promise has(DOMString cacheName); [NewObject] Promise open(DOMString cacheName); [NewObject] Promise delete(DOMString cacheName); [NewObject] Promise> keys(); }; dictionary MultiCacheQueryOptions : CacheQueryOptions { DOMString cacheName; }; // https://w3c.github.io/ServiceWorker/#self-caches partial interface mixin WindowOrWorkerGlobalScope { [SecureContext, SameObject] readonly attribute CacheStorage caches; };