1

我想使用 css 或 js 隐藏移动浏览器的滚动条。

::-webkit-scrollbar {
    display: none;
}

此 CSS 适用于桌面浏览器 chrome,但不适用于移动 chrome。当页面滚动时,滚动条仍然显示。我想知道是否有办法实现它?

4

1 回答 1

0

I don't know about a css solution but you could use iSrcoll-4. It was created to add scrolling functionality to older mobile devices. You can hide the scroll bar it generates by setting vScrollbar to false

var myScroll = new iScroll('wrapper', { hScrollbar: false, vScrollbar: false });
于 2013-04-25T18:01:47.773 回答