window.close and self.close do not close the window in Chrome

后端 未结 16 1796
孤城傲影
孤城傲影 2020-11-21 05:48

The issue is that when I invoke window.close() or self.close() it doesn\'t close the window. Now there seems to be a belief that in Chrome you can\

16条回答
  •  傲寒
    傲寒 (楼主)
    2020-11-21 06:03

    In tampermonkey now you can use

    // @grant        window.close
    

    And then just simply call

    window.close();
    

提交回复
热议问题