Progressive Web App (PWA) is a way to server the web application as if it a native app on all Versions of devices with the different operating systems without making various editions of the main app for each System, And Wikipedia says about PWA
“Progressive Web App (PWA) is a term used to denote a new software development methodology. Unlike traditional applications, progressive web apps are a hybrid of regular web pages (or websites) and a mobile application. This new application model attempts to combine features offered by most modern browsers with the benefits of mobile experience.”.
- Web Manifest
- Service Worker
- Static website
Any PWA contains some steps that happen for the first time when the user adds it to the device, and others that happen regularly when the application is offline or connected to the Internet, which makes it behave like the original applications now I will give you these steps.
- the website asks the user to add as an icon on the home screen of their phones based on how frequently they visit the website.
- when the user accepts the request after that the website cache the manifest, static website data, and the server workers in the local storage of the browser that makes it faster after initial loading
- Then PWA sends a web application manifest to the system containing:
- knew The name of the web application
- Links to the web app icons or image objects
- The preferred URL to launch or open the web app
- The web app configuration data
- The default orientation of the web app
- The option to set the display mode, e.g. full screen
- Then it was time for the better part, the role of the service worker that is can respond to Web / HTTP requests By Implement a programmable network proxy. It can cache content when that service is Unavailable, serve that content later in the document and check if a remote server is available. Service workers operate separately from the context of the main document, and the server worker life cycle divided into three steps:
- Registration: Registration involves telling the browser the location of the service worker in preparation for installation.
- Installation: if there is no service worker instilled, the Installation occurs in the browser for the Progressive Web app, or if there is needed update to the service worker.
- Activation: if all the PWAs pages are closed the Activation occurs so that there is no conflict happen between the previous version and the updated one. since only a single service worker can be active for a domain.
- Progressive, for every user, needs on the browser, on the device, offline, online.
- Can work offline
- Fast, after initial loading
- Always up to date
- Installable, without the use of an App Store.
- Responsive, For all devices
- Safe, Served via HTTPS.
- Re-engageable, maintain engagement with the user by push notifications.
- shareable Can easily be linked via a URL.
- Behave like native apps
in the end, PWA is a very powerful technology that very important for every web developer must learn and use based on the Features we describe before, Who knows, this could be your speciality.