SVG icon in PWA manifest.json - how to set it for all sizes?

Viewed 10552

Is there any way now to specify that an SVG icon in "manifest.json" for a PWA should be used for all possible sizes? (Chrome/chromium is my main target now. Firefox will hopefully follow.)

    "icons": [
        {
            "src": "path-to-icon.svg",
            "purpose": "maskable any",
            "sizes: "???"
        }
    ],
2 Answers

"sizes": "any" didn't work for me. I used the following configuration:

{
    "src": "logo.svg",
    "sizes": "48x48 72x72 96x96 128x128 256x256 512x512",
    "type": "image/svg+xml",
    "purpose": "any"
}
Related