4 ms·
I'm not sure this would work, in general. A page will often render slightly differently based on the size of the window, so whatever size is "reported" to the w
by 333c 4y ago
I'm not sure this would work, in general. A page will often render slightly differently based on the size of the window, so whatever size is "reported" to the webpage would end up being how big the page is rendered.
- daneel_w 4y agoOnly if there's active use of e.g. JavaScript or some server-side scripting that needs the info for some processing, for example using JavaScript to place a floating modal flush against bottom/right corner. The browser itself doesn't need to relay the dimensions "to the webpage" in order for HTML/CSS to render as any specific size, nor to achieve responsive/scaling UI design that adjusts to the window size.
- rhn_mk1 4y agoIt does, via media queries that include resources loaded at specific shapes.
- daneel_w 4y agoWhat I'm trying to convey is that it's a misunderstanding that the server renders the page for the browser, and that reporting innerHeight/Width properties to the web server ("the webpage") is a requirement for having anything pop up on the screen.