I usually use this obtained document.documentelement.clientwidth?document.doc umentElement. clientHeight. but I just found that some people do not apply these two attributes. I want to ask you how to accurately obtain the width and height of the browser? I generally use the obtained document.doc umentElement. clientWidth; document.doc umentElement. clientHeight. but I just found that some people did not apply these two attributes. I want to ask you how to accurately obtain the browser width and height?
Reply content:
I generally use the obtained document.doc umentElement. clientWidth; document.doc umentElement. clientHeight. but I just found that some people did not apply these two attributes. I want to ask you how to accurately obtain the browser width and height?
Window. innerHeight get screen height window. innerWidth get screen width
Window. innerHeigh