Skip to content
This repository has been archived by the owner on Jan 23, 2021. It is now read-only.

Releases: GoogleChromeLabs/sw-precache

5.2.1

24 Jan 17:43
Compare
Choose a tag to compare

What's New?

The 5.2.1 is a small patch release the bumps the dependency on update-notifier to a version that is fully compatible with recent node releases.

Significant PRs Since Previous Release

  • #344 rev update-notifier

Thanks

Thanks to @markFromMST and @cdanielsen for reporting and fixing the update-notifier dependency issue.

5.2.0

13 Jun 17:19
Compare
Choose a tag to compare

What's New?

The 5.2.0 release includes support for using Buffer objects, in addition to the previously supported Strings and glob patterns, as the values in dynamicUrlToDependencies.

It also includes a number of enhancements and clarifications to the project's README.

Significant PRs Since Previous Release

Thanks

Thanks to @papandreou, @mbj36, @mlcdf, and @sp00m for their contributions!

5.1.1

04 May 19:25
Compare
Choose a tag to compare

What's New?

The 5.1.1 includes a change to always remove the hash (a.k.a. URL fragment) portion of the a request's URL before determining whether sw-precache should respond to it. This accounts for new behavior in Chrome and Firefox, as per an update to the service worker specification.

It also fixes a bug in the sw-toolbox integration that preventing the successResponses option from being set properly.

PRs Since Previous Release

Thanks

Thanks to @whmountains for reporting the underlying issue with hashes, and to @mahwy for their fix to the successResponses configuration.

5.1.0

13 Mar 01:00
Compare
Choose a tag to compare

What's New?

The 5.1.0 release includes one new piece of functionality, as well as a number of fixes for broken links in the documentation.

dynamicUrlToDependencies Supports a String Value

As described by @HenrikJoreteg, you can now supply a string as the value corresponding to a given "dynamic" URL, and the hash of that string will be used to determine whether or not the cache entry for that URL needs to be updated.

PRs Since Previous Release

Thanks

Thanks to @HenrikJoreteg, @natecox, @vernondegoede, @rmacklin, and @denar90!

5.0.0

16 Feb 17:21
Compare
Choose a tag to compare

What's New?

The 5.0.0 release includes a number of significant changes, including one that will require all existing caches to be repopulated with fresh entries.

Accommodate Restrictions Around Redirected Responses for Navigations

As described in more detail in this issue, browsers have imposed an additional restriction that prevents a service worker from responding to a navigation request with a response that was obtained via a redirect.

In practice, this is unlikely to affect most sw-precache users, but it did affect some who explicitly had HTTP redirects set up covering their / and /index.html URLs.

To accommodate this new restriction, sw-precache will now create a "clean" copy of any redirected responses prior to added them to its caches. The 5.0.0 release of sw-precache will impose a one-time repopulation all of its caches after you deploy an updated service worker, and those new cached entries will contain "clean" entries for redirected responses.

Require node v4.0.0 or Higher

node versions less than 4.0.0 are now officially end-of-lifed, and we have dropped support for them in the latest sw-precache release. In practice, that means we've been able to update some dependencies in our package.json to point to newer releases that in turn required node 4.0.0.

Perform the dontCacheBustUrlsMatching check against the URL's path

This was always the intentional behavior, but previously developers who used dontCacheBustUrlsMatching would find that the regular expression was applied to the full URL, including the hostname. As of this latest release, the regular expression is only applied to the URL's path, so that it could pick up versioning information that's explicitly included in the file names of resources.

Add update-notifier to the CLI

To notify users of the CLI about new releases moving forward, we've added update-notifier to the CLI.

PRs Since Previous Release

Thanks

Thanks to @bertho-zero for their contributions!

4.3.0

05 Jan 18:40
Compare
Choose a tag to compare

What's New?

The 4.3.0 release includes a change to explicitly set the redirect: 'follow' option on requests used for precaching.

It also includes a fix for a bug that prevented a regular expression from being used for the cache.origin configuration option in runtimeCaching, and a bug that prevented navigateFallbackWhitelist from being set via the CLI.

PRs Since Previous Release

Thanks

Thanks to @JLHwung, @mikestead, and @kevinphelps for their contributions!

4.2.3

23 Nov 22:47
Compare
Choose a tag to compare

What's New?

The 4.2.3 release includes fixes to the command-line interface, ensuring that both the stripPrefixMulti and dontCacheBustUrlsMatching options are supported.

Significant PRs Since Previous Release

Thanks

Thanks @Fridus for their contribution.

4.2.1

19 Oct 20:45
Compare
Choose a tag to compare

What's New?

The 4.2.1 release downgrades several external dependencies to versions that are compatible with the node v0.1x runtime.

Significant PRs Since Previous Release

Thanks

Thanks @chenav for initially reporting the incompatibility.

4.2.0

19 Oct 13:53
Compare
Choose a tag to compare

What's New?

The 4.2.0 release brings the devDependencies/dependencies for the project up to date, including requiring the latest release of sw-toolbox.

It also clarifies the documentation and examples around the external configuration file passed to the sw-precache command-line-interface via the --config option. The code has always supported either a JSON file or a CommonJS module for configuration, but passing in a CommonJS module offers a cleaner syntax and allows developers to use JavaScript objects, like regular expressions, that can't be expressed as JSON. The examples now encourage the use of CommonJS module for the --config value.

Significant PRs Since Previous Release

Thanks

Thanks to @mactookmyname for their contribution leading to this release.

4.1.0

21 Sep 19:55
Compare
Choose a tag to compare

What's New?

The 4.1.0 release brings with it a number of fixes to make the command-line sw-precache interface compatible with a wider array of configuration options, along with additional control over the generated service worker file's lifecycle, and clarifications and enhancements to the documentation.

It also fixes a bug that prevented the service worker from falling back to a network response when a cached entry is manually deleted from the cache.

New skipWaiting and clientsClaim options

Developers can now opt-out of using skipWaiting() and clients.claim(), in the generated service worker file, via the new skipWaiting and clientsClaim options. They both are enabled by default, which matches the behavior in previous versions of sw-precache.

Significant PRs Since Previous Release

Thanks

Thanks to @yangchenyun, @eauc, @dandv, @TalAter, @Alexendoo, @TimvdLippe, @asolove, and @ithinkihaveacat for their PR contributions!