July 2018
Intermediate to advanced
354 pages
8h 51m
English
Precaching is not limited to mission-critical assets. You can most likely identify many assets that will be commonly used, but are not mission-critical to your application's success. You can still use the service worker install event to cache this set of assets, but choose not to make them dependent on the event completing. This is known as precaching assets without dependency.
In this scenario, you will also trigger the precaching of these network assets, but you will not return the cache.addAll method in the event.wait until call. The assets will still be added to the cache, but will not hold the install event open until all of the assets are cached.
This technique gives you the ability to minimize the latency ...
Read now
Unlock full access