<script>
 
window.onresize = function () {
 
var Width = window.innerWidth//浏览器窗口的内部宽度(包括滚动条)
 
|| document.documentElement.clientWidth
 
|| document.body.clientWidth;
 
var Height = window.innerHeight//浏览器窗口的内部高度(包括滚动条)
 
|| document.documentElement.clientWidth
 
|| document.body.clientHeight;
 
console.log(Width, Height);
 
}
 
</script>

 

相关文章:

  • 2022-12-23
  • 2022-01-08
  • 2022-12-23
  • 2021-10-28
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-07-15
  • 2022-12-23
  • 2022-12-23
  • 2021-10-18
相关资源
相似解决方案