Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to find usable screen size in Javascript

Tags:

javascript

I know we get the screen size using screen.height and screen.width. I am interested in knowing how to find the usable screen area using Javascript. This is like screen height minus address bar height minus toolbar etc.

like image 535
Nitin Nanivadekar Avatar asked Oct 19 '25 11:10

Nitin Nanivadekar


1 Answers

For most browser you can read window.innerWidth and window.innerHeight, for Internet Explorer its document.documentElement.clientWidth and document.documentElement.clientHeight, I think...

like image 198
Karl-Bjørnar Øie Avatar answered Oct 21 '25 05:10

Karl-Bjørnar Øie