Minimum Viable Favicon Code

前端 未结 1 1036
鱼传尺愫
鱼传尺愫 2021-02-05 07:57

I\'m confused about what\'s the simplest way to get favicons working on the majority of handsets and browsers.

1) Some sites suggest that it is enough to use:

         


        
1条回答
  •  日久生厌
    2021-02-05 08:30

    The code in solution 3 is correct but outdated. Precomposed Touch icons were deprecated in iOS 7 and Android Chrome does not support 196x196 icons anymore, but 192x192 (it really won't use anything above 192x192; full disclosure: I'm the author of this article).

    So:

    
    
    
     
    
    
    
    
    

    If you can place favicon.ico in the root of the web site, you can even skip its declaration, since IE looks for /favicon.ico by convention.

    0 讨论(0)
提交回复
热议问题