Screen.availHeight

概述

返回浏览器窗口在屏幕上可占用的垂直空间,即最大高度。

语法

iAvail = window.screen.availHeight

示例

js
if (window.screen.availHeight !== window.screen.height) {
  // something's in the way!
  // use available to size window
}

规范

Specification
CSSOM View Module
# dom-screen-availheight

浏览器兼容性

BCD tables only load in the browser