How to disable inertial scrolling on body for iOS browsers?
Add this to the body
element's CSS:
-webkit-overflow-scrolling: auto;
The default for -webkit-overflow-scrolling
is touch
. That tells iOS devices to use "inertial" scrolling. The docs: https://developer.mozilla.org/en-US/docs/Web/CSS/-webkit-overflow-scrolling
@meuwka answer achieves your goal, but in a roundabout way—it works because div
elements have -webkit-overflow-scrolling: auto;
as their default.
You can use div with overflow property, it kill smooth iOS scroll
<body>
<div class="scroll">
long long text...
<div>
</body>
Css
html,
body {
height: 100%;
margin: 0;
overflow: hidden;
}
.scroll {
overflow: auto;
height: 100%;
}
http://jsbin.com/palixi/edit