> Browsers don’t have direct measuring methods and require stupid workarounds, that’s it.
Oh? There are the old-school e.offset{Top,Right,Bottom,Left} etc methods for measuring the DOM stuff, and there's Visual Viewport API (experimental) for more advanced use cases:
https://developer.mozilla.org/en-US/docs/Web/API/Visual_View...