Since Chrome M31, you can set up your web app to have an application shortcut icon added to a device’s homescreen, and have the app launch in full-screen “app mode” using Chrome for Android’s “Add to homescreen” menu item.
New in Chrome M39, you can define the metadata associated with your web application in a JSON-based manifest. The manifest provides a way to wrap metadata about a web application into a single file. Using this metadata in conjunction with Add to Homescreen, you can create launch experiences more comparable to native applications.
Would be very cool to see this fully supported. Could do some interesting things with AppCache while at it.
Perhaps better worded as “still missing couple of features that chrome requires.”
Whilst the manifest.json and the meta tag are part of what is required there is still a matter of following before the “add to homescreen” will be seen:
Site must be delivered over HTTPS (hopefully Let’s Encrypt support will get this one for everybody).
Must have a service worker registered on your site (I didn’t spot one in Discourse’s code).
The user has visited your site twice over two separate days during the course of two weeks.
By using @tgxworld work, I just added more entries to get a better app feeling.
This PR makes the window standalone (no address bar), adds the header background color to the Android top bar and uses the Discourse background color on the splash screen background so the transition is smoother.
Sorry what I meant is that the color customisation should only target either the theme_color or the background_color. I think we’ll want to avoid a case where setting a secondary color ends up affecting the background color as well. For the theme_color, I think it is safe to default to the header color.
Appear on the second visit: The user has visited your site at least twice, with at least five minutes between visits.
If the user dismiss the banner it never comes back: If a user dismisses the banner, will it appear again? No. Not unless the user clears their history. We want to make sure users have a good experience. We will likely be changing all the heuristics over time.
The implementation can get better, we can defer the banner till we feel like.
Also, we can log Dismiss and Accept to make some stats.
Looks like you’re working on this one which is great because this is linked with my earlier post about trying to get as much screen real estate as possible when in landscape mode. I remembered that I’d used this feature to add a home page icon for www.whatpub.com and after doing that, the Google toolbar is missing, i.e. it’s full screen and looks much more like a native app. However when I’ve just tried this with Discourse, it’s stuck in portrait mode - rotate to landscape doesn’t work. Rotate does work with home page shortcuts as www.whatpub.com rotates happily.