Service Worker Packages
Below is the list of service worker packages that Workbox provides. Each packages serves a specific need and can be used together or on its own.
workbox-background-sync
Use background sync to reliably make a network request even if the user is offline.
workbox-broadcast-update
Send messages to pages (via Broadcast Channels) when a cache is updated with a new response.
workbox-cacheable-response
Restrict which requests are cached based on a response's status code or headers.
workbox-core
Alter log levels and change cache names via
workbox-core
. Contains shared code used by all Workbox libraries.
workbox-expiration
Removed cached requests based on the number of items in a cache or the age of the cached request.
workbox-google-analytics
See how users are interacting with your site when they are offline.
workbox-navigation-preload
Enable navigation preload, to get a network response for navigation requests faster.
workbox-precaching
Easily precache a set of files and efficiently manage updates to files.
workbox-range-request
This modules provides support for responding to a
Range:
request using a slice of previously cached data.
workbox-recipes
Easily use common workbox patterns without needing to set them up yourself from individual packages.
workbox-routing
Routes requests in your service worker to specific caching strategies or callback functions.
workbox-strategies
A set of runtime caching strategies that will handle responding to a request, normally used with
workbox-routing
.
workbox-streams
This modules provides support for composing a response from a series of streaming sources.
Window Packages
Workbox provides modules that run in the window context and complement the service worker packages.
workbox-window
A module that helps with registering a service worker, managing updates, and responding to lifecycle events.
Node Modules
Workbox provides a set of Node modules that make it easy to generate a list of files to precache in your service worker or create a complete service worker that you can use without writing any code.
Workbox CLI
Generate a complete service worker, inject a precache manifest or copy the Workbox files from the command line.
workbox-build
An npm module that can generate a complete service worker, inject a precache manifest and copy the Workbox files.
workbox-webpack-plugin
As part of your Webpack build process add Workbox and precache assets.
Loader (CDN)
Workbox provides a way to load its service worker packages from a CDN (or custom endpoint). This makes it easy to get started with Workbox without having to set up a build process.
workbox-sw
Manages dynamic loading of Workbox service worker packages as needed and provides additional helper methods.