- [Instructor] Now we have successfully sent a message…from the page to the service worker.…What about the other way around,…like a service worker sending a message to the page?…The first difference that we have…is that we don't have one page.…The service worker can be controlling several clients…at the same time.…So it's not like one to one…like the page to its controller.…So we need to broadcast a message to all of them,…while at least trying to find one particular client,…the one that we are interested in,…into sending a message.…
To do that,…we will work in the service worker JS file of our project.…And, for example,…what we can do is that after we cache all the files…we want to send a message to all our pages…so they can alert the user that a new version is available…because we have just updated all the assets.…Remember the service worker has no way…to send a message to the user,…so we need to create that message from the page.…
And for that we're going to send an actual low level message…to the page…saying, hey page do you want to alert the user…
- Service worker life cycle
- Registering service workers
- Handling service worker events
- Updating service workers
- Acting as a network proxy
- Configuring cache storage
- Communicating with clients
- Optimizing web performance
Skill Level Advanced
Web Portfolio Projects: Binding and Propagationwith Leigh Lawhon1h 9m Intermediate
1. A New Citizen for the Web
2. Work with Service Workers
3. Acting as a Network Proxy
4. Cache Storage
5. Work with APIs in the Service Worker
6. Tips and Tricks for Web Performance
Next steps1m 55s
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.