Deprecated, import worker.dart instead. ignore: annotation_with_non_class
- Represents the storage for Request / Response object pairs that are cached as part of the ServiceWorker life cycle.
Type definitions for service_worker_api 0.0
Definitions by: Tristan Caron github.com/tristancaron
TypeScript Version: 2.1
An CacheOptions object allowing you to set specific control options for the matching done in the match operation. @property ignoreSearch A Boolean that specifies whether the matching process should ignore the query string in the url. If set to true, the ?value=bar part of http://foo.com/?value=bar would be ignored when performing a match. It defaults to false. @property ignoreMethod A Boolean that, when set to true, prevents matching operations from validating the Request http method (normally only GET and HEAD are allowed.) It defaults to false. @property ignoreVary A Boolean that when set to true tells the matching operation not to perform VARY header matching — i.e. if the URL matches you will get a match regardless of the Response object having a VARY header or not. It defaults to false. @property cacheName A DOMString that represents a specific cache to search within. Note that this option is ignored by Cache.match().
- Represents the storage for Cache objects. It provides a master directory of all the named caches that a ServiceWorker can access and maintains a mapping of string names to corresponding Cache objects.
- Extends the lifetime of the install and activate events dispatched on the ServiceWorkerGlobalScope as part of the service worker lifecycle. This ensures that any functional events (like FetchEvent) are not dispatched to the ServiceWorker until it upgrades database schemas, deletes outdated cache entries, etc.
- The ExtendableMessageEvent interface of the ServiceWorker API represents the event object of a message event fired on a service worker (when a channel message is received on the ServiceWorkerGlobalScope from another context) — extends the lifetime of such events.
- The parameter passed into the ServiceWorkerGlobalScope.onfetch handler, FetchEvent represents a fetch action that is dispatched on the ServiceWorkerGlobalScope of a ServiceWorker. It contains information about the request and resulting response, and provides the FetchEvent.respondWith() method, which allows us to provide an arbitrary response back to the controlled page.
- The parameter passed into the oninstall handler, the InstallEvent interface represents an install action that is dispatched on the ServiceWorkerGlobalScope of a ServiceWorker. As a child of ExtendableEvent, it ensures that functional events such as FetchEvent are not dispatched during installation.
- The Notification interface of the Notifications API is used to configure and display desktop notifications to the user.
- The parameter passed into the onnotificationclick handler, the NotificationEvent interface represents a notification click event that is dispatched on the ServiceWorkerGlobalScope of a ServiceWorker.
- The PushEvent interface of the Push API represents a push message that has been received. This event is sent to the global scope of a ServiceWorker. It contains the information sent from an application server to a PushSubscription.
- The PushManager interface provides a way to receive notifications from third-party servers as well as request URLs for push notifications. This interface has replaced functionality offered by the obsolete PushRegistrationManager.
- The PushMessageData interface of the Push API provides methods which let you retrieve the push data sent by a server in various formats.
- The PushSubscription interface provides a subcription's URL endpoint and subscription ID.
- Key values that may be stored in a PushSubscription.
- Object containing optional subscribe parameters.
- Represents a service worker. Multiple browsing contexts (e.g. pages, workers, etc.) can be associated with the same ServiceWorker object.
- Represents the scope of a service worker client. A service worker client is either a document in a browser context or a SharedWorker, which is controlled by an active worker.
- Represents a container for a list of Client objects; the main way to access the active service worker clients at the current origin.
- A ServiceWorkerGlobalScope object represents the global execution context of a service worker.
- Represents a service worker registration.