This project is not covered by Drupal’s security advisory policy.

What is a Progressive Web App?

Much like web components, progressive web apps (PWA) refers to a set of browser features designed to allow websites to behave more like native applications on mobile devices. As far as features are concerned it means:

  • offline, with total control over caching,
  • OS integration,
  • push notifications,
  • background synchronization.

What does the module do?

The main benefit of this module is the use of Service Worker for caching and offline capabilities. Once the Service Worker is active, page loading is faster:

  • All JS and CSS files will always be served from cache while being refreshed in the background. Same thing as Stale While Revalidate in Varnish.
  • All pages are fetched from the network (as before) and a copy is kept in cache so it will be available when offline.
  • Most images are not cached to prevent the cache from becoming too large. This might change in the future. For now, a fallback image is sent for any uncached image.

Now the website is ready for faster loading and offline browsing. More flexibility is planned on fetch strategies for the D8 version. The module will also create a configurable manifest.json file to make the website installable on some browsers.

Configuration

Visit the configuration page and fill in what you need. To change the logo used in the manifest file the only way now is to implement hook_pwa_manifest_alter(&$manifest) and set the icons property.

Browser support

In order:

  1. Chrome/Opera (leading implementation)
  2. Firefox (very close to Chrome)
  3. Edge (in development)
  4. Safari (no information)
  5. UC Browser (no information)

Service Worker is truly a progressive enhancement, so browsers without support will work exactly as normal. However it will make things significantly better for browsers with support. Also worth noting that the cache used by a PWA is also a new cache defined by the Service Worker spec.

Project Information

Downloads