Google pushes new scheme for native-like Web apps

23.12.2015
Web apps are dead. Long live Web apps.

Dissatisfied with the quality of Web apps compared to their native cousins, Google is pursuing its Progressive Web Apps concept, which looks to combine the best of the Web and the best of apps. Intended for any form factor, Progressive apps load quickly even on questionable network connections, send push notifications, and have an icon on the home screen.

"The way that we think of Progressive Web Apps is they use modern Web capabilities, they deliver an app-like user experience," said Alex Komoroske, Google group product manager for the Chrome platform, in an interview. "Also they evolve from just pages and browser tabs on mobile into top-level apps, all with the low friction of the Web."

Progressive Web Apps, he said, are "a consciousness raiser, helping developers see that they can do more than they sort of thought they could do with the Web."

Several technologies are key to Progressive Web Apps. One is an application shell architecture, in which HTML, CSS, and JavaScript load fast, are cached, and enable dynamic content to populate a view. "Think of your app's shell like the bundle of code you'd publish to an app store if building a native app -- it's the load needed to get off the ground, but might not be the whole story. Keep your UI local and pull in content dynamically through an API," according to the Google Developers Web page.

Then there's Service Workers, in which a script runs in the background in the browser, separate from the Web page, responding to events like network requests. A Google Chromium project, Service Workers supports offline experiences and enables development of experiences that load quickly upon returning to them.

App Install Banners enables a Web app to be easily added to a home screen without leaving the browser. Push and Notifications, meanwhile, features events in which the server supplies a message to the Service Worker, which then sends the information to the user. (The W3C manages the Push and Notification APIs.) Apps are served via HTTPS to prevent tampering with content.

In a blog post earlier this year, Alex Russell, a Web developer working on Chrome, Blink, and the Web Platform at Google, explained that with Progressive Web Apps, the site starts out as a regular tab but is built with such capabilities as Transport Layer Security (TLS) and Responsive Design. "When launched from the home screen, these apps blend into the environment; they're top-level, full-screen, and work offline."

He adds, "When users engage with Progressive Apps enough, browsers offer prompts that ask users if they want to keep them. To avoid spaminess, this doesn't happen on the first load," Russell said. Building immersive apps using Web technology "no longer requires giving up the Web itself," he said. "Progressive Apps are our ticket out of the tab, if only we reach for it."

Google does not see Progressive Web Apps as strictly the domain of its Chrome browser; Mozilla also has participated, Komoroske said. "Actually, we've been co-developing these with Mozilla since the very beginning." While Google sees use of Progressive Web Apps concepts like Service Workers being in an early stage, growth is happening, said Komoroske. For example, Google sees 350 million push notifications a day and 2.2 billion page loads a day using Service Workers.

(www.infoworld.com)

Paul Krill