JavaScript event [removed] not triggered

后端 未结 8 1040
无人及你
无人及你 2021-02-01 01:15

I\'ve got the following code in a website:

 window.onload = resize;
 window.onresize = resize;

 function resize(){
  heightWithoutHeader = (window.innerHeight -         


        
8条回答
  •  北海茫月
    2021-02-01 01:57

    I think what's probably happening here is that your window.onload is being overridden later, check to make sure that it's not via things like

    You can check this by alert(window.onload) in your re-size function, to see what's actually attached there.

提交回复
热议问题