Prevent “overscrolling” of web page

前端 未结 8 2411
星月不相逢
星月不相逢 2020-11-28 01:23

In Chrome for Mac, one can \"overscroll\" a page (for lack of a better word), as shown in the screenshot below, to see \"what\'s behind\", similar to the iPad or iPhone.

8条回答
  •  慢半拍i
    慢半拍i (楼主)
    2020-11-28 02:04

    Bounce effect cannot be disabled except the height of webpage equals to window.innerHeight, you can let your sub-elements scroll.

    html {
        overflow: hidden;
    }
    

提交回复
热议问题