Search code examples
androidprogressive-web-appsmanifest.json

Do you need to repack and reupload your apk when you update manifest.json?


I developed a Progressive Web App by making a website and then using https://pwabuilder.com and then uploading the resulting apk to the Google Play Store.

This all works, but I accidentally set the display property in my manifest.json to fullscreen.

I've since rectified this and updated my manifest.json to instead be standalone, but for some reason, it's not applying the change to the downloaded app.

If I go to my actual website and hit "Install App" then Chrome can to the "Add to home screen" trick, and it works there, but for some reason it does not work with the app.

Does anyone know why this is? Do I have to reupload the app or something? But that doesn't make much sense to me, because I'm pretty sure the manifest.json is not bundled with the app.

I tried uninstalling and reinstalling the app, restarting my phone, clearing my browser cache, clearing the app data, and even installing it on a new phone, but it still retains the fullscreen attribute.

Does anyone know why this might be, or how I can fix it?

The reason why I don't want it to be fullscreen is because when the user does a back swipe on their phone, it temporarily shows the phone status bar (where the time is) and then bumps all the content. I want the status bar (where the time and battery percentage are, etc.) to ALWAYS be visible.


Solution

  • The manifest.json is really just for the PWA in an android bundle the equivalent is AndroidManifest.xml

    In your case I'm guessing you've just put the PWA in a webview and put it on the store, or directly added the PWA to the (play store only).

    The short answer is yes you'll need to make a new release for most changes to take effect when distributed via the play/app stores.

    When packed into an app, or downloaded from the store the files are hosted locally on the users device.

    If I might add a small suggestion to poll a 'latest' version number from the server of what should be the latest version, if the user loads their app/PWA up it can check if the version numbers match and if not automatically perform update steps like clearing caches, unregistering the service worker and reloading the source.