history.pushState in Chrome make favicon request

后端 未结 1 1877
刺人心
刺人心 2021-02-19 14:53

code :

var newurl = window.location.protocol + \"//\" + window.location.host + window.location.pathname +\"?\"+ queryStr; 
window.history.pushSt         


        
相关标签:
1条回答
  • 2021-02-19 15:07

    It looks like a bug in Chromium browsers. See this open issue.

    But there seems to be a workaround if you use base64 image as href the request won't occur.

    <link rel="icon" type="image/png" href="data:image/png;base64,iVBORw0KGgo=">
    

    See this question.

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