You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've been in the process of improving the docs (beta docs here) and when I got to the overflowX / overflowY methods I was like, whoa these are gonna sound confusing and most people aren't going to use them anyway. We'd had these in there as handlers for inViewport methods, but since version 0.5 we're using getBoundingClientRect and overflowX / overflowY are no longer used internally. IMO it makes sense to depreciate them in 0.6 unless...are there objections? The code is below. It's a native equivalent to $(document).height() - $(window).height() (dims info here) When it's all gzipped the size difference is minimal but still seems like we may as well cut them now rather than support them forever.
functionoverflowY(){// Get the number of pixels that the document width exceeds viewport width.varhtml=document.documentElement// document height minus viewport height,difference=Math.max(html.offsetHeight,html.scrollHeight,document.body.scrollHeight)-html.clientHeight;return0<difference ? difference : 0;}
The text was updated successfully, but these errors were encountered:
I've been in the process of improving the docs (beta docs here) and when I got to the overflowX / overflowY methods I was like, whoa these are gonna sound confusing and most people aren't going to use them anyway. We'd had these in there as handlers for
inViewport
methods, but since version 0.5 we're usinggetBoundingClientRect
and overflowX / overflowY are no longer used internally. IMO it makes sense to depreciate them in 0.6 unless...are there objections? The code is below. It's a native equivalent to$(document).height() - $(window).height()
(dims info here) When it's all gzipped the size difference is minimal but still seems like we may as well cut them now rather than support them forever.The text was updated successfully, but these errors were encountered: