当前位置:网站首页>Solve the problem of page flicker caused by browser scroll bars
Solve the problem of page flicker caused by browser scroll bars
2022-08-01 05:22:00 【collector】
Fix the page flickering problem caused by browser scroll bars
Description
When my webpage was initially loaded, the content of the webpage did not occupy the entire height. As I added content later, when the content was close to the bottom of the browser, the scroll bar suddenly appeared, and the page flickered.
css solution
1 Mode 1
/*method 1 recommended*/.wrap-outer{margin-left: calc(100vw - 100%);}First, .wrap-outer refers to the parent of the centered fixed-width body, if not, create one.
If the flicker is caused by the global scroll bar, you can also try setting it to thebodytag, but test it yourself.
like mybody{ margin-left: calc(100vw - 100%); }
2 Method 2 Style html
html{margin-right: calc(100% - 100vw);overflow-x: hidden;}Method 2 After my test, the browser will not flicker, but it will cause the scroll bar below me
notto appear.
边栏推荐
猜你喜欢

中国的机器人增长

备战金九银十,如何顺利通过互联网大厂Android的笔面试?

Robot_Framework: commonly used built-in keywords

【MySQL必知必会】 表的优化 | 充分利用系统资源

About making a progress bar for software initialization for Qt

(2022牛客多校四)A-Task Computing (排序+动态规划)

(Codeforce 757) E. Bash Plays with Functions

WPF入门项目必知必会-初步了解数据绑定 binding

MySQL-数据操作-分组查询-连接查询-子查询-分页查询-联合查询

2022/07/29 入职健海JustFE团队,我学到了高效开发(年中总结)
随机推荐
用控件当画笔获得bitmap代码记录
微信小程序接口调用凭证(获取token)auth.getAccessToken接口开发
数据湖:数据同步工具NiFi
Qt Widget project loading example of qml
【音视频】srs直播平台搭建
y83. Chapter 4 Prometheus Factory Monitoring System and Actual Combat -- Advanced Prometheus Alarm Mechanism (14)
Selenium: JS operation
Hunan institute of technology in 2022 ACM training sixth week antithesis
冲刺金九银十,Android开发面试(内含面试资料|面试题|源码)
Robot_Framework: commonly used built-in keywords
(2022 Niu Ke Duo School IV) K-NIO's Sword (Thinking)
WebSocket实现聊天功能
Selenium: upload and download files
NUMPY
Selenium: Popup Handling
AspNet.WebApi.Owin 自定义Token请求参数
【MySQL必知必会】 表的优化 | 充分利用系统资源
Use controls as brushes to get bitmap code records
中国的机器人增长
Flip letters using string container