Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upSupport the W3C Web App Manifest (and Add to Homescreen/Desktop) #15505
Labels
Comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
It would be nice to have Servo parse W3C Web App Manifests and Add to Homescreen (or Desktop/Applications/Dock).
Web-app developers today are using manifests by adding to their HTML documents a tag:
<link rel="manifest" href="manifest.webmanifest">. And in themanifest.webmanifestis a JSON blob of some useful metadata (see this example).A powerful feature enabled by manifests is the ability to "install" manifests to a user's homescreen/desktop. Per the spec, the UA can decide how to design the experience of discovery + installation, as well as the filesystem/OS integration (for installing and launching).
Here are some useful resources on manifests and the current support:
And some useful links on "Add to Homescreen" support (using manifests):
Here's an overview of the current browser support:
.apkon the phone that's really just a shortcut to launch Chromium as a "progressive web app" (PWA) from a particular URL (i.e., thestart_urlin the manifest) with a particular display mode (e.g.,standalone,browser, etc.) - and boot from a Service Worker, etc. (The.apkalso has an Android Intent manifest, which intercepts any URLs on the system if they get loaded and match thescopefor the installed web app.)chrome://flags/#enable-add-to-shelfflag). With ATS, a native app gets installed in the user'sApplicationsdirectory (based on the OS). The application is just a tiny executable that launches Chrome at a particular URL for that web app.In Chrome for Android, on a web app, users have the ability to manually "Add to Homescreen" (watch this video of the user flow). In addition to manually adding/pinning a site, with Chrome for Android's ATH and desktop Chrome's experimental ATS support, Chrome has set these default requirements and "user-engagement" heuristics for whether to automatically show a prompt to the user:
start_url(served on the same origin; if not supplied, defaults to/index.html)display(valid display modes arefullscreen,standalone,minimal-ui,browser)HTTPSI know this is information overload, but I figured I'd type this all up for any future dev who is interested in potentially adding first-class web-app manifest+launcher support to Servo. Especially on the desktop, there are some very compelling opportunities to provide the ability to launch web apps (e.g., games, PWAs, and hybrid apps [e.g., Slack, Spotify, Ghost, Atom, Visual Studio Code, etc.] come to mind that are currently being packaged as Electron apps and distributed through app stores).