Service Workers are the core components of Progressive Web Apps (PWA), because they allow caching of resources, which will help in offline experience and push notifications, which help for re marketing and engagement, two of the main distinguishing features that up to now set native apps apart.
A Service Worker is essentially programmable proxy between web page and the network, it gives ability to intercept and cache network requests, effectively giving the ability to create an offline experience for web app, which is one of the biggest advantages of native app over web app.
Service workers also work with some other interfaces like:
- Cache API
- Fetch API
- Offline Support
- Precache assets during installation.
- Caching network requests using Fetch API
- Engagement and Re Marketing using Push Notifications via Notification API
- Works on background thread so that UI doesn’t get effected or wont have lag.
- It can work even when app isn’t running on the browser.
You can essentially make a web app give a feel of native app with the help of Service workers and best part is it does not have to be installed on customers mobile and does not have to code in native language.
Here is the small Introduction about Service workers.
Feel free to comment to this post or you can drop an email at firstname.lastname@example.org.
Thanks for dropping by !! Keep watching this space for latest updates in tech and frameworks.