> We are working with the new Microsoft Edge browser to take advantage of the Hosted App Model for Progressive Web Apps (PWAs) – converting the web app manifest into an app manifest, package the additional web content into an MSIX package and register it. In this model, a PWA is its own independent app registered to the system even though it is being hosted by Edge.
Can a shared, system-wide Electron runtime be far behind?
Thats probably why they switched Edge to chromium. Instead of each electron app running its own copy of node and chrome, those components can be build into the os, which is much better for battery life.
Even their flagship app, teams, is running its own copy at the moment.
My understanding is that monopoly by itself is not illegal but it is the abuse of one’s market position in one thing to gain advantage in another. Not saying this is correct, just, or legal, just saying that’s what I think is how things are at least in the US.
Microsoft has already updated Window's native web-view to Edge, from IE. There are already some projects that take advantage of this and enable multi-platform app creation, with executables much lighter than Electron. A good example is https://github.com/zserge/webview. I have tried its Rust binding, and it works very nicely.
How is a shared runtime much lighter than electron? While you can share some memory, I doubt it's most of it.
If I check the dozens of Chrome processes on my machine, the largest part of their working sets is private, which is evidence against significant memory sharing.
One aspect of "lightness" is transfer & disk: initial download duration, storage size per app (often over 100 MB for apps with embedded Chromium), and the size of each app update which often needs to update the embedded Chromium too, if they're being responsible. There is no "LTS" version of Chromium.
I don't know much about Chrome's architecture, but are you sure each tab/window/origin has a separate set of all processes?
It seems reasonable to only run the security sensitive parts in a dedicated process per origin and run other tasks in a central process for all web pages.
From what I understand, Chrome's processes communicate a lot via message-passing. You probably don't need large amounts of shared memory for that.
The weight of a bunch of DLLs, type information etc for chromium is actually pretty sizable. An electron app spins up 6 processes on average last time I checked, more sometimes. The v8 team has had to invest a lot into reducing bloat from per-process duplication of data and also found ways to minimize startup time.
The largest part being private doesn't mean saving 10-20mb per process is insignificant. With a few electron apps open I'm easily losing a few hundred megs to electron overhead and many machines don't have that much RAM, especially laptops.
Each electron app also needs its own copy of centralized services like the i/o process, where a single chrome instance can share that across all tabs. An OS-level PWA implementation could share it across all PWAs and electron apps too.
I can recommend trying this out with the Spotify web app.
It is genuinely difficult to spot that it’s actually “just” a website.
When you lock windows while it’s playing it shows up with media details like album art, play/pause etc.
It is additionally “registered” in the start menu, and correct icons and windows taskbar behaviour is used, making it virtually indistinguishable from a native app.
To be pedantic, that is using a precursor to this model, with a UWP app hosting nothing but a web view. This would be similar but conceptually simpler and with less boilerplate.
And a shared, system-wide Android runtime. This sounds like a great path towards continuity across the Surface product line from desktop to mobile, given the mobile Surface devices being powered by Android coming this year.
That’s essentially what progressive web apps are once they’re installed. They use all the resources of the browser so they only take up as much disk space as their HTML/CSS/JS.
This was a major feature in IE9-11, that you could run basically a UI-less modifiable web application without noticing* that it's running on an embedded browser.
Electron is a similar ideal, but not on the OS level. They are just recreating the best aspects of IE for Chromium, and we will be better for it.
> We are working with the new Microsoft Edge browser to take advantage of the Hosted App Model for Progressive Web Apps (PWAs) – converting the web app manifest into an app manifest, package the additional web content into an MSIX package and register it. In this model, a PWA is its own independent app registered to the system even though it is being hosted by Edge.
Can a shared, system-wide Electron runtime be far behind?