Home >Web Front-end >JS Tutorial >js gets the height of the visible area, text and screen resolution of the web page_javascript skills
The width of the visible area of the web page: document.body.clientWidth
The height of the visible area of the web page: document.body.clientHeight
The width of the visible area of the web page: document.body.offsetWidth (including the width of the edges)
The height of the visible area of the web page: document.body.offsetHeight (including the height of the edge)
Full text width of the web page body: document.body.scrollWidth
Full text height of the web page body: document.body.scrollHeight
Scrolled height of the web page: document.body .scrollTop
The left side of the webpage being scrolled: document.body.scrollLeft
The upper body of the webpage: window.screenTop
The left side of the webpage body: window.screenLeft
High screen resolution: window. screen.height
Width of screen resolution: window.screen.width
Screen available work area height: window.screen.availHeight
Screen available work area width: window.screen.availWidth
Because I haven’t been able to remember these, I should be able to remember them if I look at them frequently
With this, I can dynamically load image codes