nuxt-community / pwa-module

Zero config PWA solution for Nuxt.js
https://pwa.nuxtjs.org
MIT License
1.24k stars 171 forks source link

How to switch off favicon? #452

Open DitheringIdiot opened 3 years ago

DitheringIdiot commented 3 years ago

In the documentation it's not clear how to remove this code from the markup:

<link data-n-head="ssr" rel="shortcut icon" href="/favicon.ico">

I've tried the following options:

pwa:{
    icon:false
}
pwa:{
    meta:{
        favicon:false
    }
}

Is there a way to do this that I haven't understood?

The reason I'd like to remove the favicon from my markup is actually something to consider. By default all browsers (except for seamonkey) in the absence of a <link rel=icon> look for a /favicon.ico at the root domain. There's also a good case to be made for not using the shortcut keyword made here.

lkjimy commented 3 years ago

I disabled the icon module just like you did. Try deleting the cache inside node_modules at node_modules\.cache\pwa\icon.

pwa: {
  icon: false,

  manifest: {
    // ...
  }
}

The reason for me was Chrome warning about the [any, maskable] purpose on every image. Generated all images myself and added them manually.