Chrome Web Summit finds Web apps struggling to survive against other native apps.
Google is once again trying to present web apps that will be on par with native applications.
In a blog post published on Monday, Pete LePage, developer advocate on Google's web team, said: "We want to bridge the capability gap between web and native apps and make it easier for developers to create great experiences for consumers on the web."
Striking a balance between web and native code has been one of Google’s most fervent dreams for about a decade. It was then that Google executives first claimed that the web had won. It was in the midst of the golden age of mobile apps, and it quickly became clear that web development couldn’t compete with native platform code, at least on mobile devices.
In 2016, Google’s platform overhaul took the form of a push for Progressive Web Apps (PWAs), web apps that are fast, engaging, and work offline. In 2017, we saw the introduction of the Chrome User Experience Report to help developers understand web app performance issues and a way to embed content into Android apps called Trusted Web Activity.
This year, Google partners have committed to designing and developing a set of new APIs, combined with public feedback and input from other browser makers, that bridge the enduring gap between web and native apps.
Google refers to this set of browser feature extensions using the name of a poisonous fish, proj-fugu. You can see this project, which is still in progress, here . It includes:
Web Share Target API, which provides websites with a way to receive user-shared content and register it on devices so that it appears in sharing interfaces.
Async Cookie API, which exposes HTTP cookies to Service Workers (background processes) and provides an asynchronous alternative to document.cookie.
Wake Lock API, to prevent phones from locking the screen while a web application is active.
File System API, also known as Writable Files API, which provides web applications with greater access to the native file system.
User Idle Detection API, to detect when users are away from their keyboard or the screen is locked.
Scheduled Notification API, also known as Event Alarms, an API for executing an arbitrary task at some point in the future.
Web HID API, to improve how browsers interact with peripheral devices.
Proj-fugu also includes efforts to implement geo-based support and geo-tracking, and to enable websites to be registered with the host operating system as MIME type handlers (useful for the Web Share Target API).
LePage describes these new APIs as part of an effort to "make the web a first-class platform for developing applications that run in any browser, with any operating system, and on any device.".
Google has published a Capabilities to share information about the browser API project and encourage others to contribute new features.
Another part of this effort involves websites being able to compete with native apps, which now seems more feasible.
To that end, the Chrome team has introduced Squoosh, a web application (or website) for image compression. The application, which loads quite quickly, as its main page is small (~36KB), relies on WebAssembly (Wasm) to quickly compress images using a variety of codecs. Google has also released Workbox V4 beta, which provides tools to simplify building PWAs, and an updated version of its load time analysis service, PageSpeed Insights (PSI).
In addition to the above, some education-related projects were also created: web.dev, an interactive learning website for web development that is integrated with Glitch, and Service Worksies, a tutorial on how to use Service Workers.
Finally, those responsible for Chrome's V8 engine are making several optimizations to speed up async operations.
