Zakaria Shahed
Zakaria Shahed

Reputation: 2697

Duplicate icon Progressive Web Apps add to home screen Android

For Android, I create feature add to the home screen so that user can take the taste of native apps.Here I have a problem with if I visit my site second time by clearing cache and cookie using the browser then Apps suggest me again to create home screen And if I add again then 2 icons added on my screen.I found https://m.aliexpress.com also have the same type of problem

Is there any solution for the duplicate icon.Thanks advance for your help!

The meta

<meta name="mobile-web-app-capable" content="yes">
<meta name="application-name" content="My App">

Upvotes: 1

Views: 577

Answers (1)

abraham
abraham

Reputation: 47843

The behaviour you are seeing is because the home screen icons are in fact just URL bookmarks and the Android OS does not provide an API to find what URL bookmarks have been added to the home screen. Browsers will not prompt users to add to home screen if they have previously done it but that doesn't stop users from manually duplicating the icon.

There is a solution is in the works and it's called WebAPK. WebAPKs basically build a minimal Android app based around your web manifest and installs that. Once there is a WebAPK installed browsers can query to see if it's installed.

You can read some additional details around PWA issues and WebAPK on Android Oreo takes a bite out of Progressive Web Apps

Upvotes: 1

Related Questions