Testing the Service Worker

In order to test if our service worker works, we will have to load our application, and then disconnect our browser from the internet.

Checking Where the Data Comes from

Using Chrome Developer Tools, it's easy to see where a particular resource is being retrieved from.

Using the Network tab in Chrome Developer Tools, you can see what files are being retrieved, where the data comes from, and how long it took the browser to fetch those resources.

The following screenshot shows a normal page request, where each file is downloaded from the web server:

Checking Where the Data Comes from

In the following screenshot, in the Size column, you can see that the data is ...

Get Beginning Server-Side Application Development with Angular now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.