XF 2.2 Progressive web app

Mobile app installation
Mobile first. We hear it again and again, and with over half of all web traffic coming from mobile devices, it's more important than ever to provide your mobile visitors with a great experience.

Of course, XenForo 2 is built on a fully responsive design that gracefully adapts to any display size and makes using XenForo a pleasure on all devices, but now we're taking it a step further by enabling any XenForo site to become a progressive web app.

Progressive web what?

Okay, let's back up a little. Imagine a technology that allows a web site to appear and behave like an app without having to produce native code for each platform, or go through any vendor's App Store equivalent.

Progressive web apps, or PWAs, aim to bridge the gap between websites and native applications on both mobile and desktop devices using a series of emerging web standards. Push notifications, a feature introduced in XenForo 2.1, are a popular example of one such standard. In XenForo 2.2, we're expanding our support for these standards by making XenForo installable, implementing more graceful offline handling, and adding support for the badging API.

Setting it up

It's important to note that, like push notifications, making full use of these features will require a few extra steps to set things up.

Additionally, as with push notifications, these features are only available on devices and browsers that fully support PWAs. Would you care to take a guess as to what the most notable exceptions might be? As you may have suspected, once again Safari on macOS and any iOS-based browsers are the culprits due to Apple's ongoing failure to implement industry standards. While Safari on both macOS and iOS does support graceful offline handling, it does not support installation or badging (more on that below) at this time.

We would encourage you to make your frustrations known in public by applying virtual tar and feathers to Apple employees online until they relent and get their act together... or at least voice your support for these standards by continuing to reach out to @webkit on Twitter or the webkit-help mailing list. Officially, the best place to communicate with Apple is via their product feedback channels, and presumably they won't be able to continue to ignore a deluge of feature requests for the same thing... 🤔

Requirements

To make full use of these features...
  • Your XenForo installation must be accessed over SSL / HTTPS
  • Your site must have a relatively short title of 12 characters or fewer
  • You must publish a pair of square icons for your site, one at 192px and another at 512px.

Setting a short title

Publishing a pair of icons

What do PWAs look like?

If your site meets the requirements, your visitors will automatically be given the option to install your 'app' on their device.

The precise details of the interface and the circumstances permitting installation can vary by browser and in some cases can depend on the degree of interaction with your site a user has had.

When browsing with Chrome on desktop or Android, the app can be installed via the address bar on both mobile and desktop devices. On supported mobile devices, we also display a conspicuous yet unobtrusive banner in the off-canvas menu.

Mobile app install banner
Mobile app installation

Desktop app installation

Once the app is installed, it is readily available in exactly the same way as a native app. On mobile devices, that means it can be opened via an icon on the home screen. On desktop devices, it can be opened by searching your system or even pinning the app to your taskbar or dock.

Mobile app home screen
Desktop app home screen

Some devices will display a splash screen while the app is being loaded. The splash screen is automatically generated from the icons and background color of your style.

Mobile app splash screen

For most devices, we set the app to display a minimal interface. The elements of this interface also vary by browser, but most importantly include navigation controls. For Android devices running Chrome, we are able to use the native pull-to-refresh and back-button navigation controls, so we do without any additional interface.

Mobile app
Desktop app

If a user tries to open or navigate the app without a proper network connection, we display a simple offline message.

Mobile app offline page
Desktop app offline page

Chrome-based apps recently introduced support for application badging, which allows the app to indicate unread messages or alerts directly on its icon.
We are hopeful more browsers will support the badging API in the future.

macos-badge.png
Desktop app badging (Windows)

Looking toward the future

The PWA specification and standards are constantly evolving. We will continue to monitor them as time goes on in order to always provide the best possible experience on all devices.
 

hzg7

Member
I don't think the PWA is setup properly here to work in iOS. I have yet to dig into it but I use a couple other PWA apps on my iOS devices and have so for a couple months now. The forum doesn't appear to work properly and just opens in a new safari browser instance still. The other apps do not do this.

One decent example is Gab.com. Even though it doesn't prompt, you can add to home and it becomes a standalone PWA.
 

djbaxter

Well-known member
You sound like that you just want to argue here.

I'm just going to wait for one of the developers of the app to answer instead of getting some imbecile who wants to argue with people.

Why doesn't this work properly then?

Are you trying to scam us with something that is supposed to work but doesn't?

Some of us have Macs and some of us don't have only android phones.
Wow. Now THAT is the way to guarantee that nobody at all is going to go out of their way to help you.

Have a nice day.
 

Max Taxable

Well-known member
Some of us have Macs and some of us don't have only android phones
In this thread this is explained. iOS does not currently natively support the PWA or PUSH. Later in this thread it is also explains how to complain to Apple about it.
Additionally, as with push notifications, these features are only available on devices and browsers that fully support PWAs. Would you care to take a guess as to what the most notable exceptions might be? As you may have suspected, once again Safari on macOS and any iOS-based browsers are the culprits due to Apple's ongoing failure to implement industry standards. While Safari on both macOS and iOS does support graceful offline handling, it does not support installation or badging (more on that below) at this time.
 

Lawrence

Well-known member
You sound like that you just want to argue here.

I'm just going to wait for one of the developers of the app to answer instead of getting some imbecile who wants to argue with people.

A statement of fact is not an argument.

As been pointed out, complain to Apple. With enough complaints they may end up deciding to support PWA.

Stay safe, be kind, :)
 

Pawn Studios

Active member
The forum doesn't appear to work properly and just opens in a new safari browser instance still.
They only allow chrome and android to use 'stand-alone' mode, and put iOS devices in minimal UI mode. Not sure why they did this, I have edited the code in my forum to allow 'stand-alone' for iOS as well, and the PWA works properly in testing. See this suggestion for some more details and give it an up-vote:
 

JoyFreak

Well-known member
They only allow chrome and android to use 'stand-alone' mode, and put iOS devices in minimal UI mode. Not sure why they did this, I have edited the code in my forum to allow 'stand-alone' for iOS as well, and the PWA works properly in testing. See this suggestion for some more details and give it an up-vote:
You can do this with this free guide https://xenforo.com/community/resources/joyfreak-custom-pwa.8123/
 

jasculs

Member
So it's not even working in any aspect on iOS. I can get other PWA from other sites to work by adding to home screen from iOS but Xenforo doesn't work at all in any aspect. Android users have no issues. Can you guys edit it so it at least works in some capacity with iOS?
 

deslocotoco

Well-known member
Hello guys,

Just asking if are any kind of road map features for PWA and how this resource is developing around the world and the plans to implement on XF.

My users are loving this option, but i can't track how many of then are using and specially, if new features are going be implemented in the future.

It's looks like a 'beta' version for me. The main page takes some time to fully load (using AMS as landing page), there is no Splash Screen or "loading" bar. The App works on iOS only if the site is "fully charged", specially if you use Ads.

Unfortunately Apple make this look like a amateur implementation on their systems. I hope this turn the table around a little.
 

djbaxter

Well-known member
Why Firefox won't work on iOS devices?
Firefox does work on iOS devices. I use it on my iPhone and iPad all the time. Just download the app from the App Store.

Or are you asking why the Progressive Web App doesn't work on iOS devices with Firefox as the default browser?
 
Top