Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UIwebview(IOS) BUG:当页面一直在滚动,js不执行 #136

Open
mishe opened this issue Jul 20, 2016 · 2 comments
Open

UIwebview(IOS) BUG:当页面一直在滚动,js不执行 #136

mishe opened this issue Jul 20, 2016 · 2 comments

Comments

@mishe
Copy link
Owner

mishe commented Jul 20, 2016

最近在做一个微站,需要做一个页面效果,当元素出现在屏幕中时,可以看到元素是有一个小变大的动画过程,在模拟器动画流畅的一笔,在手机的浏览器效果也在接受的范围内,但在微信中,效果一塌糊涂。只要不停地上下滚动,页面没有任何的动画效果。

用了一些调试方法后,发现在微信中,只要页面不停地在滚动,JS就不会被执行,滚动操作挤占了所有的JS执行时间。

不论你的JS是用setTimeout,setInterval,还是Raf方式写的,都不会被执行。

@mishe
Copy link
Owner Author

mishe commented Jul 20, 2016

查到一个资料,在2012年有人反馈过类似的问题,但浏览器端的滚动缓动时间比较短,没有微信短那么夸张
http://q.cnblogs.com/q/33012/

@mishe
Copy link
Owner Author

mishe commented Jul 20, 2016

比较靠谱的问题来源及解答:https://segmentfault.com/q/1010000004453730

@mishe mishe changed the title 微信BUG:当页面一直在滚动,js不执行 UIwebview BUG:当页面一直在滚动,js不执行 Jul 20, 2016
@mishe mishe changed the title UIwebview BUG:当页面一直在滚动,js不执行 UIwebview(IOS) BUG:当页面一直在滚动,js不执行 Jul 20, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant