mercredi 5 avril 2017

web app banner install

I'm using this page: http://ift.tt/2cEP0Vx to create a web app banner install.

I have the sw.js as service worker in public/admin/ I have registered with success the service worker and i have the manifest.json in public/admin too like this

{
  "name": "Web App Install",
  "short_name": "Admin",
  "icons": [
    {
      "src": "/admin/mstile-70x70.png",
      "sizes": "36x36",
      "type": "image/png"
    },
    {
      "src": "/admin/mstile-70x70.png",
      "sizes": "48x48",
      "type": "image/png"
    },
    {
      "src": "/admin/mstile-70x70.png",
      "sizes": "72x72",
      "type": "image/png"
    },
    {
      "src": "/admin/mstile-70x70.png",
      "sizes": "96x96",
      "type": "image/png"
    },
    {
      "src": "/admin/mstile-70x70.png",
      "sizes": "144x144",
      "type": "image/png"
    },
    {
      "src": "/admin/mstile-70x70.png",
      "sizes": "192x192",
      "type": "image/png"
    }
  ],
  "start_url": ".",
  "display": "standalone",
  "related_applications": [{
            "platform": "web"
        }],
    "related_applications": [],
    "prefer_related_applications": false
}

the link of service worker is: http://ift.tt/2nJf4mj the link of manifest.json is http://ift.tt/2oC31Lp

but i'm getting an error on trying install the web app the error is

"Site cannot be installed: no matching service worker detected. You may need to reload the page, or check that the service worker for the current page also controls the start URL from the manifest"

Can someone help me please. Thanks in advance. Carlos Vieira

Aucun commentaire:

Enregistrer un commentaire