Making viewport units work properly in Mobile Safari

A typical issue with the well supported Viewport Relative Units (you know: vh, vw, vmin, and vmax) that bothers me a lot is that MobileSafari (Safari on iOS) takes the height of the address bar into account for 100vh. Take a look at the footer of that first block in the screenshot below: since its […]

Prevent overscroll/bounce in iOS MobileSafari (CSS only)

Know this bouncy overscrolling behaviour that browsers have been doing whenever you reach the “edge” of the page its contents? Sometimes you’ll want to disable this. Now, there’s no need to resort to JavaScript and hijack touchstart, as the little CSS snippet below can prevent the rubber band scrolling: html, body { position: fixed; overflow: […]