No More Posting New Topics!

If you have a question or an issue, please start a thread in our Github Discussions Forum.
This forum is closed for new threads/ topics.

Navigation

    Quasar Framework

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search

    PWA - Add to home screen issues

    Help
    1
    3
    2312
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • S
      sonicviz last edited by sonicviz

      Hi,
      I’m testing a simple PWA and working on testing the Add to Home screen functionality as laid out in https://developers.google.com/web/fundamentals/engage-and-retain/app-install-banners/

      ie:
      "Testing the app install banner
      Once you’ve got your web app manifest set up, you’ll want to validate that it’s defined correctly. You’ve got two approaches at your disposal. One is manual, and the other is automated.
      To manually trigger the app install banner:

      1. Open Chrome DevTools.
      2. Go to the Application panel.
      3. Go to the Manifest tab.
      4. Click Add to homescreen, highlighted in red in the screenshot below."

      Using the default PWA framework in the manifest.json it has " “src”: “/statics/icons/icon-192x192.png”,

      I have my test app deployed to Gitlab pages but when I try the above test I get an error:
      icon-192x192.png:1 GET https://sonicviz.gitlab.io/statics/icons/icon-192x192.png 404 ()

      but the file does exist correctly at https://sonicviz.gitlab.io/fopra/statics/icons/icon-192x192.png

      If I change the manifest.json path to “src”: “./statics/icons/icon-192x192.png”, I now get an error
      file does exist correctly at https://sonicviz.gitlab.io/fopra/statics/statics/icons/icon-192x192.png

      So the relative linking is not working correctly in the manifest with gitlab it seems?

      Any clues to fix it?

      ty!

      1 Reply Last reply Reply Quote 0
      • S
        sonicviz last edited by sonicviz

        Updated the manifest file with full start url but it’s still getting the url wrong for static icons

        {
          "name": "Fopra App",
          "short_name": "Fopra-PWA",
          "icons": [
            {
              "src": "/statics/icons/icon-192x192.png",
              "sizes": "192x192",
              "type": "image/png"
            },
            {
              "src": "/statics/icons/icon-512x512.png",
              "sizes": "512x512",
              "type": "image/png"
            }
          ],
          "start_url": "https://sonicviz.gitlab.io/fopra",
          "display": "standalone",
          "background_color": "#ffffff",
          "theme_color": "#027be3"
        }
        
        1 Reply Last reply Reply Quote 0
        • S
          sonicviz last edited by

          Resolved. Seemed to be an issue purely with gitlab pages as when I deployed to netlify the offline add to homepage works just fine.

          1 Reply Last reply Reply Quote 1
          • First post
            Last post